← Back to Blog

How to Host a Team Fortress 2 Server on a VPS (2026)

Published May 4, 2026 · 6 min read · Galaxy Cloud Solutions

TF2 has had a dedicated community server scene for over 15 years and it is still going strong. Running your own server means custom maps, your own rules, no matchmaking queue, and a consistent group of regulars. A $5 VPS handles it fine — TF2 is not resource-hungry by modern standards.

⚡ Host a TF2 server from $5/mo — Use code LAUNCH2026 for 50% off

What You Need

Step 1: Install SteamCMD

sudo dpkg --add-architecture i386
sudo apt update && sudo apt install -y lib32gcc-s1 curl screen
mkdir -p ~/steamcmd && cd ~/steamcmd
curl -sqL "https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz" | tar zxf -

Step 2: Download TF2 Server Files

mkdir -p ~/tf2
~/steamcmd/steamcmd.sh +force_install_dir ~/tf2 +login anonymous +app_update 232250 validate +quit

Step 3: Get Your GSLT Token

Go to steamcommunity.com/dev/managegameservers, set App ID to 440, and generate a token. Community servers require a valid token to show up in the server browser.

Step 4: Create a Start Script

cat > ~/tf2/start.sh << 'EOF'
#!/bin/bash
cd ~/tf2
screen -dmS tf2 ./srcds_run   -game tf   -port 27015   +ip 0.0.0.0   +map cp_badlands   +maxplayers 24   +sv_lan 0   +sv_setsteamaccount YOUR_GSLT_TOKEN   -nohltv   -nobreakpad
EOF
chmod +x ~/tf2/start.sh

Replace YOUR_GSLT_TOKEN with your token. Change cp_badlands to any TF2 map name.

Step 5: Open Ports and Start

sudo ufw allow 27015/tcp
sudo ufw allow 27015/udp
~/tf2/start.sh
screen -r tf2

Installing SourceMod and MetaMod

SourceMod gives you admin tools, plugin support, and commands like sm_kick, sm_ban, and sm_map. Download MetaMod:Source and SourceMod from their official sites and extract them to ~/tf2/tf/. Add yourself as an admin in addons/sourcemod/configs/admins_simple.ini using your Steam ID.

Auto-Start on Reboot

crontab -e
@reboot sleep 20 && /home/ubuntu/tf2/start.sh

TF2 server hosting from $5/mo

Galaxy Cloud Solutions Nebula 1 plan (1 vCPU / 1GB / 20GB) handles TF2 comfortably for up to 24 players. Use code LAUNCH2026 for 50% off your first month.

Get Started