A Team Fortress 2 dedicated server lets you and your friends play on your own map rotation, with your own rules and bot count. This guide covers what setting one up actually involves: the Steam dedicated server app, the ports it needs, and the launch line. Then it shows the faster path, a hosted TF2 server by the hour with the same setup already done.
What a TF2 dedicated server is
A TF2 dedicated server runs the game with no player attached. It runs the Source engine binary srcds, holds the current map, and lets people connect over the network. TF2's dedicated server is a separate Steam download from the game itself.
- Dedicated app: The dedicated server installs under Steam app 232250. It downloads anonymously, so no Steam account or login is needed to install it.
- No game token: TF2 does not require a Game Server Login Token to run. You can boot it and connect right away.
- Store app: The game clients your friends own is app 440. That is what they launch to join.
Install the server with SteamCMD
On a Linux box you install the dedicated files with SteamCMD, Valve's command-line downloader. The anonymous login works because the TF2 server app is free.
steamcmd +login anonymous +app_update 232250 validate +quitThe launch line
Once installed, you start the server with srcds_run. Point it at the tf game folder, pick a starting map, and set the port. On TF2 the gametype comes from the map name prefix, so koth_ maps run King of the Hill, pl_ maps run Payload, and so on.
./srcds_run -game tf +map koth_viaduct +maxplayers 24 -port 27015Ports to open
TF2 is a Source game, so the port layout is small. One UDP port carries everything and the same number in TCP is the admin channel.
- 27015 UDP: Game traffic, the A2S server query, and Steam communication all share this port.
- 27015 TCP: Native Source RCON, the remote admin channel for typing server commands.
Skip the setup: hosted by the hour
A hosted TF2 server on 2hours.gg does all of the above for you. You pick a map and a size, and the server is ready in about 5 minutes. You pay by the hour and stop it when you are done, so an evening of TF2 does not mean a monthly bill or a Linux box to maintain.
- Sizes: Small holds 12 players, Medium holds 24, and Large holds 32.
- Bots included: Friendly bots fill the empty seats and leave as real players join. A navigation mesh ships for every map in the picker.
- Web console: RCON is wired to a web console on your server card, so there is no RCON tool to install or password to manage.
What the hosted server does not do
Two limits worth stating up front, both true of our default TF2 config.
- Stock maps only: The picker offers the stock maps like koth_viaduct and ctf_2fort. Custom or Workshop maps need a fast-download host, which is not part of this server.
- Vanilla, no SourceMod: No plugins, so no Versus Saxton Hale, x10, Prop Hunt or Mann vs Machine tours. It is a clean vanilla pub with bots.
- Not in the browser list: The server is not listed in the public Community browser (that needs a game login token). Share the IP and friends add it by IP.
Deploy a Team Fortress 2 server by the hour