Firefox Knowledge Base

Show content customized for:

Editing configuration files

In addition to the changes that can be made in the Options window, Firefox can further be customized by editing certain configuration files. This page describes how to access and change these files.

The suggestions offered on this page do not describe a supported function of Firefox. These suggestions have not been thoroughly tested and may cause problems in current or future versions of Firefox. These suggestions are provided solely for the convenience of Firefox users.

Table Of Contents

about:config

In certain situations, you may be required to use about:config to change or reset a preference setting. To access about:config:
In the Location bar, type about:config, and press EnterReturn.

    • The about:config "This might void your warranty!" warning page may appear. Click I'll be careful, I promise!, to continue to the about:config page.

This will display a list of user preferences, as well as a search bar (Filter:) at the top.



Double-click on a preference to change its value. To add a new preference, open the context menu (right-click) on any existing preference, go to the New menu, and select the type of preference.

Preferences changed from default values appear in about:config with a user set status and those settings are stored in the prefs.js file, located in the Firefox profile folder. Do not edit the prefs.js file directly, since you can damage your profile if you make any mistakes.

Note: Some preferences may require that you restart Firefox in order to take effect.

Configuration files

Certain situations require that you edit configuration files manually. There are three files you should know about:

userChrome.css
Used to change the appearance of the browser.

userContent.css
Used to change the appearance of web pages.

user.js
Can be used to change various preferences .

All these files are plain text files you need to create in your profile folder and can be edited using a standard text editor, such as Notepad on Windows, TextEdit on Mac, and gedit or kate on Linux.

Locate your profile folder

Before the configuration files are presented, you should know how to find your profile folder, which is where Firefox saves all your settings on your hard drive. To locate your profile folder, see How to find your profile.

userChrome.css

This file sets the display rules for various elements in the Firefox user interface and is located in the sub-folder called chrome in your profile folder. This file does not exist by default, so you need to create it before you can start adding your preferences. There's an example file that exists by default, called userChrome-example.css. You can just rename that file by removing the -example part.

userContent.css

This file sets the display rules for web content and is located in the sub-folder called chrome in your profile folder. As with userChrome.css, this file does not exist by default, so you need to create it before you can start adding your preferences. As with userChrome.css, there is an example file that exists by default, called userContent-example.css. Basically, you can just rename that file by removing the -example part.

user.js

A user.js file is an alternate method of modifying preferences, recommended for advanced users only. Unless you need a user.js file for a specific purpose, you should use about:config instead. The user.js file does not exist by default so you need to create it before you can start adding your preferences. In almost all cases, edits made using the user.js can be done via about:config, which is the recommended method.

Important: Once an entry for a preference setting exists in the user.js file, any change you make to that setting in the Options window or via about:config will be lost when you restart Firefox, because the user.js entry will override it.
Windows:

If you know how to create a file, just skip this section. Before you can create the file, you must make sure that you can see the file type extensions in Windows. Start Explorer (just click on the My Computer icon on your desktop) and select Tools > Folder Options.... Click the View tab and uncheck the Hide extensions for known file types option. Now, go to your profile folder and select File > New > Text Document. The default name New Text Document.txt should be displayed. Change the name to user.js (click Yes on the file type warning that appears).

Linux:

Assuming that you know how to create a file if you're running Linux. Just create user.js in your profile folder.


Did this article solve a problem you had with Firefox?

Was this article easy to understand?



Page last modified on Sunday 06 of July, 2008 08:19:52 PST.
Contributors to this page: Chris_Ilias , myles7897 , AliceWyman , Bo and djstsys .
- This is a help article -