Firefox Profile Preferences Cleaner

Martin Brinkmann
Aug 17, 2010
Updated • Nov 13, 2013

One thing that bothers me a lot in Firefox is how add-on uninstallations are handled. Many add-ons add preferences to the Firefox prefs.js file in the profile folder of the browser. These parameters often define values for settings that the user can change directly in the add-on's options. The problem becomes apparent during uninstallation of an add-on that is no longer needed.

Firefox ignores the custom preferences that have been created by the now uninstalled add-on, which means that they remain in the prefs.js file in the profile folder.

The number of dead preferences in the configuration file grows over time, practically with every uninstalled add-on, even though it has to be mentioned that some add-ons do not write to the preferences file.

Why is a large prefs.js file size a problem? Three different reasons come to mind. Firefox needs more time to load a larger prefs.js file. This means an extended browser startup and shutdown. The second is privacy related. It is theoretically possible to extract valuable information out of some preferences, e.g. installed add-ons or add-on specific settings that spill more information. Lastly, it may result in incompatibilities, although that is usually not the case.

In Firefox Spring Cleaning we mentioned how to clean the prefs.js file manually, to remove obsolete entries from it. This manual process reduced the file size of the prefs.js file on our test system to half its original value. Results vary highly however, depending on the number of add-ons installed, and how they make use of the preferences file. One commenter mentioned that the prefs.js file was 7 Megabytes on the computer, which is huge, and not the norm. The size normally ranges between 20 to 200 Kilobytes.

Manually cleaning the preferences has its advantages. It gives the user control over the process, but can result in errors as well.

The portable software FFPCleaner, Firefox Prefs.js Cleaner, semi-automates the process. The application displays a file browser on startup to locate a Firefox profile folder on the computer system. It supports therefor both installed and portable versions of the Internet browser.

The prefs.js file is then automatically loaded in the app. A word of warning: While it seems that the add-on filters out some core Firefox preferences in the file, it fails to locate all of them. The data displayed is made up of core preferences, existing add-on preferences and obsolete preferences of add-ons that are not installed anymore.

firefox profile cleaner
firefox profile cleaner

The data is sorted into names, and their row count, which makes identification a lot easier. It is still required to double-check the preferences to make sure that only obsolete data is removed.

FFPCleaner can create a backup of the prefs.js file before removing selected entries from the file. This is highly recommended to avoid the deletion of important information.

Placing a checkmark into the Delete box of a row in the program ensures that the preferences linked to the row get deleted when the Remove Selected button is clicked on.

Several features are currently missing in the program that would make it invaluable. It would for instance be handy to click on a preference to display all of it's preferences in prefs.js. Some extensions, like Greasemonkey, store script preferences as well. While Greasemonkey may still be installed, some userscripts may not, which means that it would make sense to only clean the entries of those scrips, and not the whole Greasemonkey entries. Currently, those have to be ignored in the program.

Furthermore, all native Firefox preferences should be filtered out automatically, to avoid deleting those. While they are probably regenerated on the next browser startup, it might mean tweaking them again in Firefox to retain the desired values. Filters should also be applied to Firefox add-ons that are still installed in the browser, with options to display them if necessary.

Finally, statistics about the removed entries would be a nice addition to the program. The application could display the size of the file before and after the operation, so that the benefits of using it become visible.

The Firefox Prefs.js Cleaner is handy program for users who want to clean their Firefox preferences file, without having to do it manually. Download available at the developer website. The software was tested on a Windows 7 64-bit test system, no problems were encountered.

The Mozilla developers should consider improving the uninstallation of add-ons, so that obsolete preferences get deleted during the uninstallation. Resolving that core issue would make more sense than adding more eye candy to the browser.

Update: The extension is no longer compatible with recent versions of Firefox. We suggest you check out Preferences Monitor instead for the browser.


Tutorials & Tips

Previous Post: «
Next Post: «


  1. Jojo said on August 17, 2010 at 9:27 pm

    A cleaner app is desperately needed! But I think I will let this mature a bit longer before trying it.

    Speaking of the FF profile, yesterday I started getting a message form WinXP that the FF profile folder was corrupted and I should run CHKDSK. I have backups so I wasn’t too worried.

    When I looked at the folder, all I could see was a single high level folder and no sub-folders! But FF kept working???

    So I shut down everything, rebooted to run a CHKDSK with automatic fix enabled and fully expected to have to restore the complete folder on restart. But to my surprise, the whole folder structure was fixed.

    What I did notice was that my profile was in two places:

    1. D:\Documents and Settings\USERNAME\Application Data\Mozilla\Profiles\PROFILENAME.default\


    2. D:\Documents and Settings\USERNAME\Application Data\Mozilla\Firefox\Profiles\PROFILENAME.default\

    #1 version had newest file was dated 5/29/2010. #2 version was the current one.

    BUT #2 was now under a new folder called FIREFOX.

    It looks like a FF upgrade changed where the default profile folder was stored around the end of May, 2010.

    I deleted the #1 profile and everything is working fine for the last 24 hours or so.

    1. Martin said on August 17, 2010 at 10:11 pm

      That’s an interesting observation Jojo, I did not experience this in W7 with the latest stable releases of Firefox. It would seem foolish on the other hand to move the profile folder on a running system. Maybe it was something else that did that?

      1. Jojo said on August 17, 2010 at 11:29 pm

        [Shrug] don’t know. I assumed it was FF.

        Maybe some add-on did it? Or I seem to recall that I had a profile problem some months back. Maybe I actually did it when I reinstalled the backup profile? Oh well…

  2. Paul(us) said on August 17, 2010 at 2:16 pm

    Hoi Martin, i have looked on to search for the location were the prefs.js file is located but there are not mention, the pref.js file location on main windows xp pro system. So sadly enough i have to ask you directly: Do you mean the prefs.js file in the Mozilla Firefox defaults/profile folder?
    Main second question is that in main Mozilla Firefox defaults/profile folder main pref.js file is 347 bytes so am i correct to assume that i do not have to clean main pref.js file?

    1. Jojo said on August 17, 2010 at 9:17 pm

      Your FF profile should be here:

      C:\Documents and Settings\USERNAME\Application Data\Mozilla\Firefox\Profiles\PROFILENAME.default\prefs.js

      347 BYTES seems way low for prefs file. I can only imagine that size would be for a brand new installation of FF.

      My prefs file is 340,000 bytes!

    2. Martin said on August 17, 2010 at 2:28 pm

      The easiest way to find your profile folder in Firefox 3.6 and later is to click on Help > Troubleshooting Information, and in the new tab on the Open Containing Folder button.

Leave a Reply

Check the box to consent to your data being stored in line with the guidelines set out in our privacy policy

We love comments and welcome thoughtful and civilized discussion. Rudeness and personal attacks will not be tolerated. Please stay on-topic.
Please note that your comment may not appear immediately after you post it.