.CFG

CFG File

Configuration File
Ask a question
QUICK ANSWER

A CFG file is a configuration file that stores settings controlling how a program, game, or device behaves. Most are plain text, so open them with Notepad++, VS Code, or Notepad - never a word processor. Always make a backup copy before editing, because one wrong value can stop the program from starting.

Developer: N/A (generic extension used by many applications) Category: Settings Files MIME: text/plain
OPENS ON Windows macOS Linux
Related: .ICA · .DS_STORE · .WMZ · .LIC

On this page

19k+ extensions indexed
Last reviewed Jul 31, 2026

Not sure what your file is?

Drop any file into our identifier - we read just the first bytes to name the format.

Identify a file

What is the CFG file format?

A .cfg file contains configuration settings for an application or program. .cfg is a generic configuration file that stores information required by a given piece of software to function properly. Files can hold data in plain text or binary format, and some applications also use encryption. Usually .cfg files hold custom settings, and can refer to an application as a whole or focus on only a subset of configuration parameters.

Because no single standard governs the extension, the internal structure is entirely application-defined. Most .cfg files are plain text and follow either a simple key=value pattern or an INI-style layout - [SectionName] headers grouping name=value pairs beneath them. On Unix and Linux systems, the same role is often filled by .conf files. Some specialized programs (certain CAD suites, game engines, or hardware utilities) produce .cfg files in a proprietary binary format; those appear as garbled text in an editor, and the originating application is needed to read them correctly.

.cfg files are typically saved in text format and can therefore be edited with any plain-text editor. They should be modified with caution, as errors can cause the related application to misbehave or refuse to start. Some programs require a .cfg file to be present, while with others such a file is optional. If no .cfg file is found, the program will use its built-in default settings.

A .cfg file can contain:

  • A list of parameters and their values
  • References to other files or directory paths
  • Section headers grouping related settings
  • Embedded parameters with values that can be overridden at runtime

In the case of .cfg files for workspaces or computer games, such files are commonly shared among users over the internet. .cfg files can be generated automatically by changing settings within the application, using dedicated configuration-generating tools, or written manually by the user.

Security & safety

RISK: MEDIUM

A text .cfg is safe to open and read. The risk is in EDITING: because a .cfg often controls whether its program starts and how it behaves, a bad value, typo, or wrong line ending can break the application or, for device configs, knock a router offline. Always copy the original to a backup before changing anything, edit with a plain-text/code editor (never a word processor that adds formatting), and change one thing at a time. Also be wary of downloaded "optimized" .cfg files for games or hardware from untrusted sources - a config can point a program at malicious paths or settings; only use configs from sources you trust.

Format details

in a nutshell
FULL NAMEConfiguration File
DEVELOPERN/A (generic extension used by many applications)since No single origin - a convention used by software since the early DOS/Windows era
MIME TYPEtext/plain
TYPEGeneric settings file - usually plain text (key=value, INI-style), occasionally a program-specific binary

Programs that open CFG files

Windows4 apps
Windows Notepad Built-in Right-click > Open with > Notepad for quick edits. Fine for small text .cfg files; lacks syntax help.
Notepad Open-source Right-click > Edit with Notepad++; it shows line numbers and syntax for safe editing. Best free choice for text .cfg files.
Visual Studio Code Free Open the .cfg to read/edit with bracket and INI highlighting. Good for larger or structured config files.
Notepad2 / Notepad3 Open-source Lightweight Notepad replacement with syntax highlighting; open the .cfg to edit. Notepad3 is the actively maintained fork.
macOS3 apps
TextEdit Built-in Open the .cfg, then Format > Make Plain Text before saving so it stays a plain text config (don't save as RTF).
Visual Studio Code Free Open to edit the config with highlighting; safer than TextEdit for structured files.
MacVim / BBEdit Open-source Open the .cfg in a code editor for precise editing. BBEdit (free mode) is a popular alternative.
Linux3 apps
GNOME Text Editor / gedit Open-source Open the .cfg to read/edit; the default GNOME editor handles config files fine.
Visual Studio Code Free Open for editing with INI/config highlighting.
nano / vim Open-source Edit in the terminal: nano file.cfg - standard for server/router config files. Back up first.

Technical details

deep spec
Primary encodingUsually plain text (UTF-8 or ASCII); some applications write .cfg files as proprietary binary
Typical syntax stylesFlat key=value pairs or INI-style [SectionName] headers with name=value pairs beneath each section
MIME typetext/plain - no dedicated IANA-registered MIME type exists for the generic .cfg extension
File signature (magic bytes)None - .cfg carries no standard header byte sequence; the format is identified by which application created it
Comment syntaxCommonly # or ; at the start of a line; the exact token is application-defined
Encryption / obfuscationSupported by some applications; certain game engines and hardware configuration tools store encrypted or obfuscated .cfg files
Section supportINI-style variants support one level of [SectionName] grouping; flat key=value files have no section hierarchy
File scopeOne application may use several .cfg files simultaneously - global, per-user, and per-workspace configs can coexist
Runtime reloadSome applications (e.g. game servers) re-read .cfg at runtime and apply changes without a full restart
Case sensitivityKey names are usually case-insensitive for Windows-targeted apps and case-sensitive for Unix/Linux targets
Line endingsCRLF on Windows-generated files; LF on Unix/Linux/macOS; most parsers tolerate both
ShareabilityGame, server, and workspace .cfg files are routinely exchanged between users and published in community repositories
EditabilityText-format .cfg files are human-readable and editable in any plain-text editor without special tooling
Functional relativesServes the same role as .ini, .conf, and .config files - the choice of .cfg extension is purely application convention
ReleasedNo single origin - a convention used by software since the early DOS/Windows era

CFG conversions

Community Q&A

asked by users
Ask a quick question
Get help from people who work with CFG files. Be specific - include your system and software version.
No account needed · answers usually within a day

No questions yet - be the first to ask about CFG files.

Frequently asked questions

How do I open a .cfg file?
Most .cfg files are plain text - open them with Notepad++, VS Code, or Notepad on Windows, TextEdit (in plain-text mode) on Mac, or gedit/nano on Linux. If the contents look like gibberish, it's a binary config and only the program that created it can open it.
Can I edit a .cfg file safely?
Yes, but make a backup copy first. Use a plain-text or code editor (not a word processor), change one setting at a time, and keep the original so you can restore it if the program stops working.
Why does my .cfg file look like random characters?
Because that app saves its .cfg in a proprietary binary format rather than text. A text editor can't display it meaningfully - change those settings through the program's own options instead.
What program creates .cfg files?
No single one - .cfg is a generic extension reused by many games, applications, and devices. Identify the owner by the folder it's in (e.g. a game's install directory) or by opening it as text to read its contents and comments.
What's the difference between .cfg, .ini, and .conf?
Practically none - all three are common names for plain-text configuration files. The extension is just a convention chosen by the developer; the formats (often key=value or INI sections) are similar.
I edited a .cfg and now the program won't start - what do I do?
Restore the backup you made, or delete the .cfg so the program regenerates a default one (you'll lose custom settings). This is exactly why copying the file before editing matters.

References

1Microsoft Learn - INI file format (key=value/[section] structure)learn.microsoft.com
2Notepad++ - free source code/text editornotepad-plus-plus.org

Keep exploring

across the database

Top extensions this week

1.AQQAQQ Instant Messenger File
2.CRDOWNLOADChrome Partial Download File
3.PARTPartial Download File
4.BINCD/DVD Disc Image (BIN/CUE)
5.MDMarkdown Document
6.RPMSGRestricted Permission Message
7.NOMEDIAAndroid No-Media Marker File
8.EXEWindows Executable (Portable Executable)
9.DATProgram Data File (generic)
10.TXTPlain Text File

Related extensions

.ICACitrix Independent Computing Architecture file
.DS_STOREmacOS Finder Desktop Services Store (.DS_Store)
.WMZWindows Media Player Skin
.LICLicense File
.CONFConfiguration File
.OVPNOpenVPN Configuration File

Free file tools

An in-browser file identifier and image converter - everything runs on your device.

Open the toolbox

Browse file extensions A-Z