28 ratings
How to Make a Dedicated Server
By Moss
Here's how to make a Half-Life server, illustrated and simplified for those who haven't calculated the exact radioactive properties of a resonance cascade.

NOTE: You will need Port Forwarding set up for this to work. Since it changes for different routers I will not cover this, but there are plenty of tutorials online.

Also, this applies to Windows. If you need help doing this on Mac or Linux, check the link in Step 1.
Ya Wanna Hear a Touchin' Story?
Well, here it is. A guide I promised to do maybe a week ago during a R3VIVE Gaming Event but scratched together from November 14-15. Here I am on 11/16 publishing the guide at 12:40 AM. So if it's a little rushed, well, sorry. I'll pick up on this guide and do a bit of editing later on.
Intro Textwall, Part 2
This guide is made so that you can make your very own HL1 server. Note that you can apply this to making servers for TFC, Ricochet, DMC, etc... but you need to do an additional step at the bottom.

In this guide, we'll set up SteamCMD (Steam, command prompt edition), download the server files, and reconfigure the server to use port 27015, run in a command prompt rather than GUI, and run the mod/game of your choice.

Why can't I just download Half Life Dedicated Server from Steam > Tools?
This used to work, but after the SteamPipe update that drastically changed the HL file architecture, the server will simply crash on startup. It's also very outdated. The only way to get the most recent server is via SteamCMD.
If you at any point have a question, just leave a comment.
Get Steam, Command Prompt Edition!
First things first... let's download SteamCMD.

What is SteamCMD?
SteamCMD is another excellent application spawned from the well of Gaben's almighty wallet.

Using its command prompt interface, it connects to the Steam servers and can download server files for you, as well as update them. Of course, we won't need to do any updating... HL and its mods haven't gotten an update in over a year.

You can download it directly from Gaben's bloggipediabookstagram, aka Valvesoftware.com.
Now, we'll open the Zip folder, which should contain a single file-- SteamCMD.exe.

We're going to make things easier on us, and make it easily accessible. I'll do this on the C Drive, since it's the first drive (and for me, my only drive), but if you prefer to store things on your Z/D/whateverthehellyourfavoriteletteris Drive, go ahead. Just remember to replace any C's with the drive letter of your choice.

I'm going to take the Zip and extract it to C:\SteamCMD. To do this, we:
  1. Go to the start menu.
  2. Click "Computer." (windows 7 ftw)
  3. Open the C Drive as if it were a folder.
  4. Right-click an area of empty space and Select New... > Folder.
  5. Name said folder "steamcmd" (without the quotes).
  6. Extract the files of the Zip you downloaded to C:\steamcmd (just click and drag the damn exe to your SteamCMD folder you just made).
SteamCMD: First Time Setup!
The first time we launch this, we need to do it through Command Prompt. Click on the Start menu, and search Command Prompt. Yup, the one with the icon that's a black bar with C:\ written. Open it up. Alternatively, pressing the Windows key and X at the same time (Windows 8+) will pull up a dialogue where you can click "Command Prompt."

Type in the following:
cd C:\steamcmd steamcmd
You will now be running SteamCMD for the first time. It will unpack into the folder and update its stuff, then after it's done you can type exit to quit it, then exit again to quit Command Prompt. Now that you've run it through Command Prompt once, you can open the folder to find everything there and next time you want to use SteamCMD, you can just doubleclick the EXE.
Force-Install HLDS!
Now, we're going to install the server to a folder called, simply enough, valveservers. Once again, putting it right in the drive (not in My Documents or any of that s:clunk:t) will be extremely helpful.

First, open up SteamCMD. It should launch and check for updates, either taking two seconds or taking up to a half a minute. Then, it'll pop up "Loading Steam API...OK."
After that message comes up, enter in the following:
login anonymous
Note that anonymous is required for HL1. If you try to login using your real account name, you'll get an obsolete server that has outdated files and no exe.

After you've logged in, you just need to type in a few more things. First, we'll tell SteamCMD where we want to install it. In this case, we want HL1 to be installed in C:\valveservers\goldsrc.

So, we type:
force_install_dir "<path-to-desired-folder"
Note that you DO need the quotes. It now knows that anything you want to install in this session goes to C:\valveservers\hl1dm or wherever you want it. Either type in the full address as seen there, or just use .\hl1dm to put it under hl1dm in your SteamCMD folder.
  • . Put this instead of C:\ or whatever to signal "whatever folder you're already in. That means C:\SteamCMD in this case.
  • .. Put this to say "Go back one folder" (if you're using C:\SteamCMD, it goes back to C, so you can then make it ..\valveservers to go to C:\valveservers).

    Next, we type in:
    app_update 90 mod valve
    You should instantly see it begin downloading.
    Altogether, here's what your SteamCMD window should look like (though you may or may not have an update taking up the empty space):
    You may get an error message once or twice, something along the lines of "Error, <computer insulting your mother in machine code> is 0x0006 on update job" or something like that. Just type the command again and It will definitely work by your third try (don't say it...).

    If it tells you that you aren't subscribed to content or that it's restricted, you forgot to type "login anonymous" and will need to do so before trying again.

    After that, you'll see it allocate space for your server, followed by downloading and installing.

    With your server downloaded, let's go ahead and begin setting up your server!
Making HLDS Slightly Less Useless!
There you have it, HLDS. It's installed and all, now what? Well, HLDS is honestly garbage. It's a simple GUI that lets you launch the server, but gives you no real control over it. Let's fix that.

First, we're going to open up the folder. It'll be under C:\valveservers\goldsrc (you should probably just make a shortcut to that folder at this point). Now find HLDS.exe.
Right click hlds.exe, and click "Create Shortcut." You can keep the shortcut there, or you can go ahead and move it somewhere else. First, for organization's sake, we're going to name it "Half-Life 1 MP Server." You can name it whatever you want, as long as you know it's HL1 and not TFC or something. Both the name and location of the shortcut will not matter; as long as you leave the real HLDS in the files, you can do whatever you want with that shortcut.
Now, once you've renamed and moved it (if you'd like to), we're going to right-click the shortcut and click "Properties." You'll see a window that looks like this:

Now go to the line that says "Target," and after the quotes you'll put in:
-port 27015 -game valve -console
Once you've done this, your box should look like this:

Now, let's launch it! We can't really use it just yet since we haven't set it up, but we need to launch it just once so that it'll verify steam and all. It'll probably crash the first time you try to launch it, but that's not a problem. So:

1) Launch it.
2) Type in: map "crossfire" (crossfire is an example, do whatever map you want)
3) If it doesn't crash, type "exit" once it's connected to Steam/VAC and idle again.
4) If it does crash, yell "F$@#ING WINDOWS 98!" and slam your fists on your keyboard repeatedly.
Now, we modify your server.cfg to give it what you want it to have.
Customizing your Server!
Go under the "valve" folder in your Half Life server's folders. You'll see near the bottom, a file called "server.cfg." Double click it. If it asks you what to do with the file, choose "Select program from a list" and choose "Notepad."
You'll see plenty of variables to edit. All you have to do is change the values on these... or add other variables to the end. For example, I can scroll to the bottom and put "maxplayers 32," and when I relaunch the server it'll have 32 players max.

One of the variables will be "hostname." Make sure to change this; nobody wants their personal server to have the default name "Half-Life..." you might as well be a TFC scout with the name Player. Also, when you change the hostname, make sure to put quotes around it, or it'll just be the first word. For example, if I made the server hostname "R3VIVE Gaming - Test Server," the server list will just say "R3VIVE" if I forget the quotes.

One more thing... for all GoldSrc games, make sure to put the two following lines at the bottom:
mp_consistency 0 sv_lan 0
The first line will allow both custom models and Valve's HD Models/Textures, and the second line will make sure it's connecting to Valve's master server and not just your LAN, so that others can join.
Change anything else you want, but make sure to keep certain things the same (gravity, maxspeed, pausable, etc).

When you're done, click File in the top corner and Save. After that, you can X out the window.

Time to play!
Play your Server!
Well, that's it. Remember to type in map "mapname" when the console window comes up for your server. Other than that, you're set!

Whenever you want to open your server, just double cilck that shortcut, and once it's loaded up, make sure your maxplayer count is set to 32 (if not, type maxplayers 32 and hit enter) and type:
map "mapname"
Your server will connect to Steam and VAC, then your server will be up and running!

You can join it yourself, and assuming you both did everything right and have Port Forwarding enabled, you'll be able to find your game under Internet listings.

NOTE: Make sure to have the "Has users Playing" filter turned off since if you just booted the server, since nobody's going to be in it if you're the first to join it.

If you want to invite others, find your server from the Internet listings and right-click it, then View Server Info. Then, you can just copy-paste the IP there. While you're at it, you should favorite your server so that you no longer have to fish it out from the complete Internet list.

If you can't find your server, check the LAN tab of the server browser. If you find it there, you either forgot to put -port 27015 in the shortcut, tried to launch the server directly (you're supposed to use the shortcut), you forgot to put sv_lan 0 into the server.cfg, or your IP changed and you need to do your port forwarding again.

If all else fails, connect with the in-game console command connect "IP goes here" .

Author Notes and all that crap!
This guide is part 1 of a 2 part series on HLDS. Episode 2 will cover TFC, DMC, and more. There was a third part giving you console commands and more, but I've "delayed" it. The irony is real.

Anyway, when I release Part 3, it'll be under either the CS 1.6 or TFC forums. Probably CS 1.6, since more people can see it that way.
Shameless Promotion of my HL1 Group!
This guide is brought to you by R3VIVE Gaming, a group I made in late September where we play GoldSrc games every Friday and Saturday night from 9-10 PM EST.

This group is temporarily on hold.

Here's to making your own servers so we can bring back HL1... or you can just share your server with your real friends, if you're funophobic.
(In Progress)
Well, I took a year to make it, but here's that TFC/CStrike server guide I meant to make long ago but kept forgetting about!

Well... in reality, it's pretty simple stuff. You just take a few steps extra from before, otherwisethe process from what you've seen above is almost identical.
Change 1: Folders
The first change: SteamCMD. When installing the server, I cannot emphasize this enough, do NOT overwrite old folders. It will NOT share the same properties, and anyone attempting to join your server will face a "STEAM identification invalid" error or something of the sort.

Find a new directory for the new server; personally, I prefer organizing by engine then name, so my own Counter-Strike/TFC servers were located in .\goldsrc\<gamename>. It can be whatever you want (for time's sake keep the name short and simple, hence why I use "tfc", "cstrike", and other short names of the sort) and will have each game separate but in an organized folder.

Here's an example of a vanilla HL1 directory vs Team Fortress Classic:
Change 2: "Mods?!"
After that, go back to my "Force-Install HLDS!" Section and note the final line: app_update 90 mod valve. What is "mod valve" for? Well, for Half-Life 1, all of the GoldSrc games share the Half-Life engine and the same AppID. As a result, you need to specify games with different mods (e.g. to install Team Fortress, app update 90 mod tfc). I have a table to show different "mod" options:
Mod Label
Game Name[/tr]
Half-Life (default setting)
Counter-Strike 1.6
Counter-Strike: Condition Zero
Half-Life: Opposing Force
Day of Defeat
Deathmatch Classic
Team Fortress Classic

Change 3: Shortcuts
Remember when we modified the shortcut of the Properties? Yeah, I don't either.

Anyway, you put in "-game valve" just as in the screenshot, but with the game you downloaded (using the same code as above). That tells the shortcut to actually launch the right game, otherwise it would just launch HL1 anyway.

After that, you'll have a working server for whatever game you're playing. Understand that changes you make to the "valve" and "cstrike" folders will do nothing for other games (and yes, CS1.6 downloads for no reason on all of the mods.
Want to make an HL2 server?
Thanks to Knappy for making an awesome guide on it, R3VIVE Gaming's HL2DM server may be up and running soon enough. The information here should also apply to other Source games.

Valve, 1998 -- For Making Half-Life 1
Valve, 2007 -- For not releasing HL3, making it even more memorable within PC
Valve, 2013 -- For the SteamPipe update that made it easier to reuse files between GoldSrc games, saving GB's of space
Valve -- For making SteamCMD and HLDS
Microsoft -- For making Windows 8.1, the greatest Windows of all time (aside from 98 SE/XP SP3)
UltimateX -- For teaching me how to do this
Me -- For being an overall badass/tryhard/obsessor
Me -- For writing the guide
< >
CHUCK_NORRIS Apr 18 @ 9:33pm 
1. i can't launch the hldm.exe after editting the shortcut target. It flashes the cmd window but that's it. Also, after I did the set_update command, i don't have anything inside the valve folder except two other folders, but no server config, etc. I assume this is why hldm is not opening properly in the console. ?
Mur Jan 31 @ 7:32pm 
oh, I have it installed on another HDD,
Moss  [author] Jan 31 @ 7:30pm 
Hard to say. Where do you have it installed? C:\<something> should be fine, but it puts up a fight when under Program Files. If it's installed to Documents, make sure to go to Documents and make sure you have "Read-Only" disabled under Properties for your HLDS folder.
Lion_4K Jan 17 @ 4:01am 
For those with issues when forwarding the ports:

Cover almost all routers, with notable exceptions of MikroTik / RouterOS *(had to learn on mine the hard way :/ serves me well for buying advanced tech).
nokee Dec 24, 2017 @ 11:35am 
hey can you accept my request i wanna chat 'bout something
S.U. Dec 17, 2017 @ 7:33pm 
I added "validate" and its still not launching but when I try hl.exe, its openning dedicated server menu.(previously it was not) I cant choose map and game type and also when I start the server, there is nothing.
Oxoтник нa Kλитop Dec 16, 2017 @ 9:20am 
Moss  [author] Dec 16, 2017 @ 9:07am 
Unfortunately, that's down to port forwarding. The process is too specific to really put down in a Steam guide, unfortunately.
Oxoтник нa Kλитop Dec 16, 2017 @ 9:06am 
Can you tell me how I can allow others to join? I went through all the steps and no one else is able to join.
Moss  [author] Dec 16, 2017 @ 8:40am 
It usually crashes on the first attempt for me. Just give it another shot. If you still can't get it working afterwards...

1) Make sure you didn't install it in Program Files or Program Files (x86). Windows protects those folders.

2) Use SteamCMD with the same directory, but replace the final command with "app_update 90 validate" (that last word is important).