What Is an INI File?

Why software programs use INI files, and how to view one

What to Know

  • An INI file is an initialization file that stores settings for a program.
  • All INI files are plain text, meaning you can open and edit them with any text editor.

This article explains what INI files are and why they're used, plus how to open or convert one.

What Is an INI File?

A file with the INI file extension is an initialization file for Windows or MS-DOS. They are plain text files that contain settings that dictate how something else—usually a program—should operate.

Various programs use their own INI files, but they all serve the same purpose. CCleaner, for example, can use an INI file to store all its different options. This particular file is stored as the name ccleaner.ini under the program's installation folder.

A common INI file in Windows, called desktop.ini, is a ​hidden file that stores information about how folders and files should appear.

How to Open and Edit INI Files

It's not a common practice for people to open or edit INI files, but they can be viewed and changed with any text editor. Just double-clicking it will automatically open it in the Notepad application in Windows.

INI file in the CCleaner program
Notepad viewing ccleaner.ini.

See our Best Free Text Editors list for some alternative text editors.

Still Can't Open It?

Many files share some of the same file extension letters, but that doesn't mean they're related or that they can be used by the same software. Source code files used by C++ compilers (.INL), and Inform 7 source code files (.NI), are two examples.

How an INI File Is Structured

INI files contain keys, or properties, and some use optional sections to group keys together. A key should have a name and a value, separated by an equals sign, like this:

Language=1033

INI files work differently across programs. Some are really tiny (a few kilobytes) with only one or two lines of information, and others can be extremely lengthy (several megabytes) with lots of customizable options.

In this example, CCleaner defines the English language with the 1033 value. So, when the program opens, it reads the file to determine in which language to display the program text. Although it uses those numbers to indicate English, the program natively supports other languages, too, which means you can change it to 1034 to use Spanish instead, for example.

The same can be said for all the other languages the software supports, but you have to look through its documentation to understand which numbers mean other languages.

If this key existed under a section that includes other keys, it might look something like this:

[Options]
RunICS=0
Brandover=0
Language=1033
SkipUAC=1

This particular example is in CCleaner's INI file. You can change this file yourself to add more options to the program because it refers to this file to determine what should be erased from the computer. This particular program is popular enough that there's a tool you can download called CCEnhancer that keeps the INI file updated with lots of different options that don't come built-in by default.

More Information on INI Files

Some INI files may have a semicolon within the text. These just indicate a comment to describe something to the user if they're looking through the file. Nothing following the comment is interpreted by the program that's using it.

Key names and sections are not case-sensitive, at least in Windows. The same effect is produced in an INI file that uses uppercase letters as one that has lowercase letters.

A common file called boot.ini in Windows XP details the specific location of the Windows XP installation. If problems occur with this file, see How to Repair or Replace Boot.ini in Windows XP.

Although it's safe to delete desktop.ini files, Windows recreates them and applies default values to them. So, if you've applied a custom icon to a folder, for example, and then delete the desktop.ini file, the folder reverts to its default icon.

INI files were used a lot in early versions of Windows before Microsoft began encouraging the Windows Registry to store application settings. Now, even though many programs still use the INI format, XML serves the same purpose.

If you're getting "access denied" messages when trying to edit an INI file, it means you don't have the proper administrative privileges to make changes to it. You can usually fix this by opening the text editor with admin rights (right-click it and choose to run it as administrator). Another option is to copy the file to your desktop, make changes there, and then paste that desktop file over the original.

Some other initialization files you might come across that don't use the INI file extension are CFG and CONF files. Some programs even stick with TXT.

How to Convert an INI File

There's no real reason to convert an INI file to another file format. The program or operating system that's using it will only recognize it under the specific name and file extension that it's using.

However, since INI files are just regular text files, you can use a program like Notepad++ to save it to another text-based format like HTM/HTML or TXT.

ConvertSimple.com has an INI to XML converter if you want to make that conversion.

FAQ
  • How do I create an INI file?

    You can use a text editor such as Notepad. Once you've added the text you want to save, select File > Save and use the .ini extension in the file name. Also, choose All Files from the Save as type drop-down menu.

  • Where can I find the Skyrim INI file?

    Open the Windows search bar and type skyrim.ini to locate the file path. You can also navigate to your Skyrim folder and find the skyrim.ini file manually. If your system is set up to hide .ini file extensions, you might see a Skyrim CONFIG file instead of an INI file.

  • Where is the php.ini file in WordPress?

    If you're self-hosting a WordPress site, open a text editor > type <?php phpinfo(); ?> > and save it as your_choice.ini in the root folder of your WordPress installation. Open it in a web browser and look for the location of the php.ini file in a section called Loaded Configuration File. If you're using a managed hosting service, check the documentation to see if you can log in and view your files from a particular menu.

Was this page helpful?