The Tool Desk
Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →Put server.cfg in your dedicated server’s tf/cfg directory. Team Fortress 2 reads the plain-text file when a map starts, so it is the right place for settings that should persist across map changes. Create the file, add only commands supported by your installed server build, restart or change map, and verify the result in the console.
Playing with friends? Godlike.Host runs hosted Team Fortress 2 servers from 10 data-center locations, with free DDoS protection.
What server.cfg does
server.cfg is a plain-text startup configuration for a Team Fortress 2 server. It stores console variables (convars) such as the server name, passwords, network visibility, logging, content policy and round limits. When the server prepares a new map, it executes the commands in the file. That makes it more reliable than typing settings into the console after players have joined.
| # | Preview | Product | Price | |
|---|---|---|---|---|
| 1 |
|
Team Fortress 2 - PC (Collector's) | $24.95 | Buy on Amazon |
| 2 |
|
The Orange Box - PC | $33.93 | Buy on Amazon |
| 3 |
|
Team Fortress Classic | $37.18 | Buy on Amazon |
| 4 |
|
Island Fortress by Game Salute | $34.00 | Buy on Amazon |
| 5 |
|
Team Fortress 2 - Cartoonified Design Decal Sticker - Graphic for Auto, Wall, Laptop, Cell, Truck... | $1.99 | Buy on Amazon |
As an Amazon Associate I earn from qualifying purchases.
Quick wins for a faster PC:
Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →Repair Windows errors before they cause bigger problemsFix Now →The file is not a program and it does not contain special Team Fortress 2 syntax. Put one command on each line. A line beginning with two forward slashes is a comment and is ignored by the game, so comments are useful for recording why a setting exists:
// Public server identity
hostname "TF2 Community Server"
// Keep this secret on a real server
rcon_password "set-a-unique-admin-secret"
The exact commands available can change with the running server build, installed server-side extensions and updates. Nodecraft’s guide, updated September 5, 2024, recommends generating the live inventory with cvarlist log cvarlist.txt. Treat that output as the authority for your installation instead of copying an old list from a forum.
#1 Best Overall
- Nine unique character classes, each providing a completely unique play experience for players of varying skills
- Advanced graphics that offers a unique game environment while providing game information within the visuals
- Support for up to 24 players
- Introduces new multiplayer game modes and support for voice chat
- Automatic updates – Stop wasting time looking for patches or new content
Dedicated server or listen server?
A listen server is created from the regular player client and normally exists only while that player is hosting. A dedicated server runs as separate server software, without requiring a player client to remain connected. A persistent server.cfg workflow is intended for the dedicated model: the machine can stay online, update through SteamCMD and load the same settings whenever it starts a map.
| Approach | Where configuration lives | What to expect |
|---|---|---|
| Listen/local server | Created through the game client | Useful for a quick session; settings and availability are tied to the host player’s client. |
| Standalone dedicated server | The server installation’s tf/cfg/server.cfg |
Suitable for a persistent community server, scheduled restarts, automated updates and independent administration. |
Install or update the dedicated server with SteamCMD
Before editing a configuration, make sure you are working in the installation that actually launches your server. The researched SteamCMD example uses application ID 232250 and installs to C:tf2_server on Windows:
Free tools Windows power users keep installed
One-click scans. No signup required.
steamcmd +login anonymous +force_install_dir C:tf2_server +app_update 232250 validate +quit
The command logs in anonymously, selects the installation directory, downloads or updates the Team Fortress 2 dedicated-server files, validates them and exits. The application ID and command were documented in a 2017 Steam Community guide; SteamCMD behavior and server files can change, so check the output for errors and confirm that the executable you launch is in the same directory you update.
- Run the update before troubleshooting a missing command or file. An out-of-date installation can produce a different convar list from current documentation.
- Ensure the account running the server can read the installation and write log files.
- Back up an existing
server.cfgbefore replacing it, especially if plugins or a hosting panel also edit configuration files.
Create server.cfg in the correct directory
- Open the dedicated server’s main installation directory.
- Open the
tffolder, then itscfgsubfolder. - Create a new file named exactly
server.cfg. It must be a plain-text file, not a rich-text document and notserver.cfg.txt. - Add one supported command per line. Use
//for comments and keep secrets out of screenshots, public repositories and shared control-panel templates. - Save the file using the encoding your editor normally uses for plain text. If the server reports strange characters or fails to parse the first command, reopen it in a basic text editor and remove formatting.
On a managed host, the equivalent operation may be an editor labelled “Server.cfg,” “Configuration files” or similar. The control panel still writes to the server’s tf/cfg location; do not create a second file elsewhere unless the host’s documentation explicitly says it uses a different path.
A practical baseline, organized by purpose
There is no universal configuration that fits every server. Start with identity, access, visibility, content policy and logging, then add mode-specific rules only after deciding how the server will be used. The following examples show the role of each setting; replace example names and secrets with your own values.
Rank #2
- Characters - Advanced facial animation system delivers the most sophisticated in-game characters ever seen. With 40 distinct facial muscles, human characters convey the full array of human emotion, and respond to the player with fluidity and intelligence
- Physics - From pebbles to water to 2-ton trucks respond as expected, as they obey the laws of mass, friction, gravity, and buoyancy
- Graphics - Source's shader-based renderer, like the one used at Pixar to create movies such as Toy Story and Monster's, Inc., creates the most beautiful and realistic environments ever seen in a video game.
- AI - Neither friends nor enemies charge blindly into the fray. They can assess threats, navigate tricky terrain, and fashion weapons from whatever is at hand
Identity and access
hostname "TF2 Community Server"
rcon_password "set-a-unique-admin-secret"
sv_password ""
hostnameis the name shown to players in the server browser and connection information.rcon_passwordprotects remote-console administration. Use a long, unique secret and rotate it if it has been exposed. Do not reuse a personal account password.sv_passwordrequires a connection password. An empty value represents an open server in the example; set a non-empty value when access should be private, and distribute it only to the intended players.
Do not confuse the RCON password with the player connection password. They serve different purposes: one grants administrative command access, while the other controls who can join.
Do these 3 things before closing this tab:
1Fix the driver behind crashes, sound loss and screen glitches2Repair Windows errors before they cause bigger problems3Scan for outdated or missing drivers - takes under a minuteInternet visibility and region
sv_lan 0
// Set sv_region to the broad region that matches the host location.
sv_lan controls whether the server is treated as LAN-only or available through the internet. The public-server example uses internet mode. sv_region reports a broad geographic region so browser listings can present the server in an appropriate area. Choose the value defined by the live convar help on your build rather than guessing a numeric code from an old post.
Content policy with sv_pure
sv_pure 1
sv_pure determines which game files clients may use while connected:
| Value | Policy described in the server guide | Operational trade-off |
|---|---|---|
0 |
Unrestricted; clients may specify any game-file location. | Maximum flexibility for custom skins, models and other content, but the weakest control over client files. |
1 |
Whitelist-based. | A middle ground: permitted files can be defined while unapproved substitutions are restricted. |
2 |
Steam-official content only. | Strictest content policy and the least room for custom client content. |
The setting is a policy decision, not a performance switch. If your community depends on custom visual content, a strict value may remove that flexibility. If consistent files and stronger cheat resistance matter more, use a stricter policy and test the player experience after changing it.
Logging and administration records
log on
sv_logfile 1
sv_log_onefile 0
sv_logbans 1
These commands illustrate the logging controls shown in the SteamCMD guide and a current public configuration dated April 26, 2026. log enables server logging; sv_logfile controls writing logs; sv_log_onefile controls whether logs are consolidated; and sv_logbans records ban-related information. Exact file names, rotation behavior and disk usage depend on the server build and hosting environment, so inspect the generated files after enabling them and arrange log retention before the disk fills.
Rank #3
Map and round behavior
// Select values appropriate for your chosen game mode.
// sv_visiblemaxplayers ...
// mp_maxrounds ...
sv_visiblemaxplayers controls the player count displayed to browsers, while mp_maxrounds limits the number of rounds in modes that use round limits. The example guides include both settings but do not establish one correct number for every map or mode. Set them deliberately: a misleading browser capacity can frustrate incoming players, and an unsuitable round limit can end a match too early or keep it running longer than intended. Use the running server’s convar help and your mode’s rules to choose values.
Apply and verify the configuration
- Stop the server cleanly if you are changing passwords, content policy or several settings at once.
- Save
server.cfgintf/cfg, then start the server using the same installation you updated. - Watch the console as the first map loads. A misspelled command normally produces an “unknown command” or related warning; fix that line instead of assuming it was accepted.
- Change map after editing a running server. Team Fortress 2 loads the file before a new map, which is why a map change is a practical way to apply updates without a full machine reboot.
- Query important values in the server console and compare them with the file: check the hostname, password state, LAN state, pure mode and logging state.
- Connect from a client that represents the real use case. Test an ordinary player connection, a password-protected connection if enabled, and an administrator RCON connection from a separate machine when possible.
Generate a fresh command inventory when you are unsure whether a setting exists:
cvarlist log cvarlist.txt
Keep that output with your server notes and regenerate it after major updates. It reflects the commands exposed by the installed build, unlike a static article or an old configuration pasted from another server.
Why settings appear to reset after a map change
Map changes are supposed to trigger server.cfg, so a reset usually means another configuration source is winning or the file was never loaded. Check these causes in order:
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
The file is in the wrong installation
Multiple test servers, SteamCMD installations and hosting-panel instances are common. Confirm that the launch command’s working directory contains the tf/cfg/server.cfg you edited. A correctly written file in an unused directory has no effect.
Rank #4
- For 2-4 players
- Ages 13 and up
- 90 minute playing time
The filename is wrong
Operating systems can hide extensions. Verify that the name is exactly server.cfg, with no additional .txt suffix, and that it is plain text.
A command is unsupported or malformed
One obsolete or misspelled line can generate an error while the remaining file loads. Remove unsupported commands, check quotation marks, and compare every convar with cvarlist from the live server.
Recommended Free Tools
A map-specific file or plugin overwrites it
Map configuration files, server-side plugins, startup scripts and hosting-panel presets may execute after server.cfg. If the console shows the desired value and then changes it later, identify the later command in the startup or plugin logs and change that source instead of duplicating the setting in server.cfg.
The value is not persistent by design
Some commands are intended for a particular map, round or session. A value can be accepted and still be reset when the game mode initializes. Confirm the convar’s flags and help text in the live console before treating that behavior as a file failure.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Security, VAC and maintenance cautions
Protect administrative credentials
Anyone who obtains rcon_password may be able to run administrative commands. Use a separate secret, limit access to the server console and panel, and replace the password immediately after an accidental disclosure. A player password protects entry; it does not protect administration.
Best Value
- Brand: decals
- Material: Vinyl
- Surface recommendation: Metal,Plastic
- Item shape: Rectangular
- Installation type: Stick
Understand the -insecure launch option
The historical Steam guide states that VAC is enabled by default and that an administrator expressly disables it by adding -insecure to the launch options. Treat that as launch-configuration guidance rather than a permanent guarantee: verify the current behavior after server updates and do not add -insecure casually to a public server where anti-cheat protection is expected.
Plan for updates and rollback
- Keep a dated backup of
server.cfgbefore edits. - Record the server build, launch options and plugin versions alongside the file.
- After an update, regenerate
cvarlist, inspect startup warnings and test a map change. - Monitor log growth when enabling several logging options, especially on a busy server.
Manual editing versus a hosting panel
| Method | Advantages | Risks and checks |
|---|---|---|
| Manual file editing | Full control, versionable text, easy to comment and reproduce on another machine. | Requires filesystem access, correct permissions and confidence that you are editing the launched installation. |
| Hosting control panel | Convenient browser editor, often with restart and map-change controls. | The panel may generate or overwrite files. Save changes through its intended interface and confirm the resulting file and console output. |
Whichever method you use, live validation is more trustworthy than a static template. A panel can simplify file access, but it cannot make an unsupported convar valid.
Choosing sensible defaults
Build the configuration around the server’s purpose. A private test server may need a player password, unrestricted content and verbose logs. A public community server generally needs a clear hostname, internet visibility, a carefully protected RCON password, a deliberate sv_pure policy and logging that fits available storage. A competitive or event server should decide round and visibility values from its published rules instead of inheriting them from a casual server.
Start small: identity, access, visibility and the content policy. Add logging and mode rules one group at a time, change map, inspect the console, and test from a real client. This isolates failures and makes it obvious which setting caused an unexpected result.
Quick Recap
Final checklist
- Dedicated-server files are installed or updated with SteamCMD application ID
232250. server.cfgis plain text attf/cfg/server.cfgin the installation that actually launches.- Comments use
//; each active line contains a supported convar and its value. hostname,sv_passwordandrcon_passwordmatch the intended access model.sv_lan,sv_regionandsv_purereflect the server’s network and content policy.- Logging, visible capacity and round limits are chosen for the host’s storage and game mode.
- The console was checked after startup and after a map change.
cvarlist log cvarlist.txtwas used whenever command support was uncertain.- No accidental
-insecurelaunch option disables the protection your public server requires.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




