How to Edit the Config for TF2

By Louis Raczka

Updated September 22, 2017

"Team Fortress 2" configuration files contain data strings that control various functions and settings, such as universal and class-specific video and audio settings, key bindings and scripts. Numerous configuration files are used to control-specific aspects of "Team Fortress 2" performance, including "config," which controls key bindings, and "autoexec," which will automatically execute any command strings in the file at start-up. Configuration files, saved with the "cfg" file extension, are plain text files you can edit with any standard text editing program, such as Notepad.


Launch your operating system's file management program and navigate to your main "Team Fortress 2" directory. The main "Team Fortress 2" directory is located under default Steam settings in "C:\Program Files\Steam\steamapps(User)\team fortress 2," where "(User)" is your Steam user name.

Double-click the "tf" folder, then double-click the "cfg" folder. Double-click a configuration file, such as "config.cfg," to open the file in your default text editor program, such as Notepad.

Disable the word wrap function. Click the "Format" menu, then click "Word Wrap" in the drop-down menu. Text will scroll off-screen instead of wrapping to the next line. Saving configuration files while the word wrap function is enabled can change the file's structure and render the file unreadable.

Make the desired changes to your configuration file, then save the file and close the text editor. The altered configuration file will be read and applied the next time you launch "Team Fortress 2."


Notepad is suitable for editing configuration files, but programs like Notepad++ include enhanced file reading and saving processes that make editing configuration files much easier and reduce the risk of file mangling.


Editing configuration files can cause "Team Fortress 2" to become inoperable. Create a backup of any files you plan to edit before editing them, then reload the backup if your edits cause "Team Fortress 2" to crash.