Thursday, June 17, 2010

Left 4 Dead 2 LAN (Offline)

Those who like to play the original Left 4 Dead with their friends locally, ergo without an Internet connection, may also want to play the sequel Left 4 Dead 2 on a local area network (LAN) as well. I've created a guide on how to host and join a local game session without relying on Steam or any other online game matchmakers.


Update (February 7, 2012)

Almost two years have passed since I created this guide and a lot of game updates have been pushed through by Valve since then. As a possible fix to recent multiplayer connection problems, create a shortcut for Left 4 Dead 2.

Open the shortcut’s properties, proceed to Shortcut tab and add the following at the end of the Target field: –insecure. Click Apply/OK to save the new setting.

CaptureEvery time you run Left 4 Dead 2, you should do so by using this modified shortcut. The guide below will not work if you don’t use the shortcut.

After following the steps above, run the game. You will then need to enable the developer console. Optionally, you can also enable automatic detection of LAN games for convenience to those who will join your hosted game. Here's how:

How to enable Developer Console:

1. At the game main menu, click Options.
2. Click Keyboard/Mouse.
3. Click Allow Developer Console and select Enabled.

Left 4 Dead 2 main menu with console open.
Click image to enlarge.
How to automatically detect LAN games:

1. At the game main menu, click Options.
2. Click Multiplayer.
3. Click Automatically Discover LAN Games and select Enabled.

With all the necessary settings set up, it's now time to host a game.

How to create or host a Left 4 Dead 2 local (LAN) game:

1. Open the Developer Console by pressing ` on your keyboard. (It is the key below Esc.)
2. Type sv_lan 1 then press Enter.
3. Type sv_allow_lobby_connect_only 0 then press Enter.
4. In the console, type map then press Space.
5. Right after you press Space all the playable maps will be displayed.
6. Use your keyboard arrows to scroll to your desired map.
7. Press Enter.

Basically the command to create a local game is this:
map nameOfMapHere gameType

An example of a map is this c5m1_waterfront. c5 stands for campaign five, m1 for chapter/map one, and waterfront the corresponding name. Those with The Passing campaign, the campaign code assignment is c6.

List of all Left 4 Dead 2 maps:

Dead Center:
c1m1_hotel   c1m2_streets
c1m3_mall    c1m4_atrium

The Passing:
c6m1_riverbank   c6m2_bedlam   c6m1_port

Dark Carnival:
c2m1_highway   c2m2_fairgrounds   c2m3_coaster
c2m4_barns     c2m5_concert

Swamp Fever:
c3m1_plankcountry   c3m2_swamp
c3m3_shantytown     c3m4_plantation

Hard Rain:
c4m1_milltown_a   c4m2_sugarmill_a   c4m3_sugarmill_b
c4m4_milltown_b   c4m5_milltown_escape

The Parish:
c5m1_waterfront   c5m2_park c5m3_cemetery
c5m4_quarter      c5m5_bridge

List of all game modes:

campaign   scavenge   realism
survival   versus     mutation

If the gameType is left blank, the hosted game will default to a campaign game with normal difficulty. To choose another mode, just type in the console the game mode after the map name.

Example: map c1m4_atrium realism

How to join a LAN game:

When the game is created, the remaining thing to do is to let other players join the game. If Automatically Discover LAN Games is enabled, Steam Group Servers may appear in the main menu which players can use to join your game.

Alternately, the console command to join is connect hostIPAdresshere.

Example: connect
Steam Group Servers (at the bottom center) appears when it detects a game.
Click image to enlarge.
When clicked, you will then proceed to this window that lists all available games.
Click image to enlarge.
Determining the host's IP address:

Determining your local IP address can be tricky when you're connected to the Internet, so it's best to stay offline when hosting a game. Anyway, the game host must type net_status in the developer console. Some data will appear afterwards. You will need to look for a phrase similar to this: "Net status for host" The numbers that appear on that phrase is the host's IP address.

Other notes and info:

This offline LAN game guide does not require Hamachi, Garena, or Steam. However, I suppose the version of the game installed on all computers must be the same.

Make sure Left 4 Dead 2 is added to the firewall exemption.

If set, players may only join this server from matchmaking lobby, and may not connect directly.

sv_lan ( def. "0" )
If set, server is a lan server ( no heartbeat, no authentication, no non-class C addresses ).


  1. works! thank you! except we found that to join the game, instead of typing "join ip", we just simply type the ip. "join" didnt seem to be a functional command.

  2. Thanks for telling me that, it should be "connect" and not "join". I corrected my post... Thanks again!

  3. For those wanting to create a LAN session on the original Left 4 Dead game, just follow the "How to create or host a Left 4 Dead 2 local (LAN) game" section of this post. Map names that contain 'vs' are versus maps.

    Joining the host's game is as simple as:

    Have fun playing!

  4. when i try this the game just goes ahead and starts, i want it to go to the lobby so that we can vote on what gametype it is and what map to go to. is there any way to make it start off in the lobby?

  5. The guide I made here was specifically made for LAN games, assuming the players are friends who can discuss which gametype the host will create.

    Anyway, you can always vote during the game.

  6. yeah i'm able to start a versus map, but the game just starts, no selection of teams or anything. the problem is that amongst my friends some of them suck and some don't, so the teams have the potential to be very unbalanced. that's why i want to get into a lobby so that we can set up the teams. is there a way to select what team you're on in versus or does it have to be random?

  7. When we play versus, we switch sides/team by pressing M during the game.

  8. please answer me.. someone..
    can we play easy mode in LAN??
    because all of the thing I see is in NORMAL mode..

  9. You can change the current map/game's difficulty during the game itself. The majority of players will have to vote yes for easy difficulty.

  10. Can i try this with a cracked, downloaded version, or it works only wiht the original -the one you buy- game?

  11. Not that I'm endorsing pirated versions of the game, I believe the guide works on those too.

  12. Hello Dear :)
    i became this message #Valve_Reject_LAN_Game
    when my friend trys to connect to my ip i do lan over hamachi :)
    can u help me?

  13. Hi,

    I'm not sure how things work using Hamachi (I haven't tried it myself). But my guess is this: type "sv_lan 1" at the game console.

  14. this guide works and it doesn't b4 any1 says anything hear me out i've done this then tryed 2 put back sv_allow_lobby_connect_only back 2 it's default number and also tryed leaving it on 0 and none of my friends can connect 2 me at all now if any1 has found a way around this please tell me and my friends want 2 play my modded builder survival maps and i also made sure that they also had the maps in the right folders so yeah let me know if theres away 2 do this properly

  15. I am not able to start the Developer Console. I'm currently using a finnish keyboard with a HP laptop and the mark (`) isn't in the same place, so the console won't start altough i know how to write (`). Any ideas? Am i doing something wrong?/ Is there a alternative route to open Developers Console?/ Is it even possible to open it with this keyboard?

  16. How can I choose to be human or zombie I keep coming up as a zombie when I create it

  17. You must be playing a Versus game. Press M to switch sides.

    1. I have another problem when I try to join a game an error comes out saying invalid protocol: expecting 2001 received 2009

    2. The problem must be version incompatibility. Your friend host probably has a different LFD2 version than yours.

  18. Whoever this was "AnonymousOct 2, 2011 02:08 PM

    this guide works and it doesn't b4 any1 says anything hear me out i've done this then tryed 2 put back sv_allow_lobby_connect_only back 2 it's default number and also tryed leaving it on 0 and none of my friends can connect 2 me at all now if any1 has found a way around this please tell me and my friends want 2 play my modded builder survival maps and i also made sure that they also had the maps in the right folders so yeah let me know if theres away 2 do this properly"

    Part of your fuckin problem is, like most gamers today you cant spell simple words. Also I couldnt comprehend what the fuck you were saying because you didnt even mkae an attempt to punctuate sentences. Is this generation really stopping at 7th grade education?!

    As for the original poster of the guide, thanks but I dont think this no longer works. I had 5 different people try this multiple times and we cannot connect to each other. I believe its been patched and you must now use source mod.

    Mr. Asshole

    1. Updated my post and added a possible fix. I hope it will work for you guys.

  19. how to play with friends not connected to the same internet...we used to play it1 year ago but i forgot it..i think its with hamachi hm?

  20. My friend not find my game... And then he connect with ip adress it says that disconect after 10 retryes. Help

    1. this means, you can not reach the host.. if u are really sure u are typing the correct ip address (ip address of the host), then check your and the hosts firewalls. this does not work over internet, you need to be on local lan (on the same router for example). maybe it works with hamachi over internet but i didnt try it out

  21. Any 1 know if the can be done with all games of Steam?

    1. nope, definetly not all games on steam, but probably all games running the source engine, having the source developer console.

  22. is this patched?

  23. iv tried every single steps that you've said out here, but may i ask, "is this instructions are for L4D2 only?" or can you atleast specify d instructions for L4D1...??? i would like to play these games offline without the use of internet... pls do respond to my concern.



    1. Here's a LAN guide for the original L4D:

  24. Not working. Conan, could you tell me which version it worked on for you? I followed yourdirections, and connection just doesn't work. The other computers simply cannot see my LAN game...

  25. I can't help you regarding this as I am not playing Left 4 Dead 2 anymore. was the last version I checked my guide to be still working on.

  26. hi :))
    can u tell me how to vote to make change the difficulty ?

  27. Why doesnt it work my console will not show up

  28. My friend not find my game... And then he connect with ip address it says that disconnect after 10 retries. Help

  29. how to play versus mode??

  30. When i change the shortcut i get the message "Unable to execute command (87)" can you please help me?

  31. when you change the shortcut, after xxxxxleft4dead2.exe'' you need to [space] before typing -insecure

    hope that helps =)

  32. Hi there. I have a problem with versus mode. When i pick map, it starts, loads, but i cant change team. When i press M it shows wait for players to login. Can you help?

    Thanks for help anyway.

  33. Hello, i have a problem with versus mode.
    Game loads, ewerything is fine, but i cant change team to zombies. When i press M, it shows UNABLE TO CHANGE TEAMS, you must wait until all players all loaded. How can i fix this?

    Thanks anyway.

    1. "You must wait until all players all loaded" That? Let all players join the game, as in really connected and roaming about in the game.


Please add comments that contribute to the topic of my post.

If you're just gonna thank me for providing you great and helpful info, why not share the post on Facebook? Or +1 it on Google+? I'd really appreciate it. :)