How to Edit a CFG File

By Chris Hoke

Updated September 28, 2017

The CFG file extension indicates a generic configuration file used by an application or game. The CFG file stores settings and preferences that are used when the software is launched. CFG files typically contain lines of text with one variable defined per line, though the information contained varies depending on the requirements of the associated software. When editing a CFG file, it is important to know which lines of code can be changed; otherwise, the application or game may be rendered inoperable. If you want to open a CFG file, you can use a text editor.

Click to select the CFG file, then click the "Edit" menu and click "Copy" (or press "CTRL" and "c") to copy the file to your clipboard. Click the "Edit" menu again, then click "Paste" (or press "CTRL" and "v") to paste a copy of the CFG file in your current directory. This creates a copy of the CFG file starting with "Copy of," which can be used as a backup.

Right-click the original CFG file, then click "Open With." If the "Open With" option does not exist on the right-click menu, instead click "Open."

Click to choose the "Select a program from a list of installed programs" radio button. Click "OK."

Click to select "Notepad" or "Wordpad" from the list. Both the Notepad and Wordpad programs are text editors that can open files with the CFG file extension. Click "OK."

Edit the contents of the CFG file by adding, deleting or modifying lines of text. The lines of code that can be edited depend upon how the software functions. Some knowledge of computer programming may be required to correctly edit the CFG file.

Click the "File" menu, then click "Save."

Tips

If the software is unable to run or generates errors after editing the CFG file, delete the edited CFG file and rename (right-click on the file, then click "Rename") the backup file created in step 1 to remove the "Copy of" text from the file name. This will restore the backup of the CFG file.

×