Firefox and the Windows Registry

So it ended up that it wasn’t that easy to switch our installer to use “Product Version” to determine what version of Firefox was installed, so I was asked to provide information on how to use the Windows Registry to determine the installed version of Firefox. Since that information is useful to everyone, I thought I would post it here.

The following registry path is where Mozilla Firefox info is contained:

HKEY_LOCAL_MACHINE\SOFTWARE\Mozilla\Mozilla Firefox

(Note that Firefox 1.5 and below used to put information in HKEY_CURRENT_USER as well. Firefox 2 does not.)

Within this registry path, there is a key, CurrentVersion. This key indicates the installed version of Firefox as well as the locale. Don’t confuse this with HKEY_LOCAL_MACHINE\SOFTWARE\Mozilla\CurrentVersion which is something else entirely.

If you need to locate the installation, there is a key under Mozilla Firefox with the same name as CurrentVersion. That key contains another key called Main that has a value for the install path (Install Directory).

Incidentally, in the screenshot, you might notice that other folder, Mozilla Firefox 2.0.0.3, which has subfolders called bin and extensions. That’s there for posterity. A long time ago, we told people that to find the plugins directory, concatenate the product and version together and then look for the plugins key as a child of that key. If I remember correctly, that’s how it was done even in the Netscape Navigator 2/3 days. You can read more detail about those keys on MDC.

Please note: I reserve the right to delete comments that are offensive or off-topic.

Leave a Reply

Your email address will not be published. Required fields are marked *

8 thoughts on “Firefox and the Windows Registry

  1. “If you need to locate the installation, there is a folder under Mozilla Firefox with the…”

    for clarity you should use “key” not folder when referring to the registry.

  2. > for clarity you should use “key” not folder when referring to the registry.

    Yeah, that is confusing.

    The Registry Editor help uses the term folders when referring to the user interface.

    “Folders represent keys in the registry and are shown in the navigation area on the left side of the Registry Editor window.”

    So in most cases when I used folder, I was referring to the UI. I’ll clean up the post a bit.

  3. Dear Mike,
    Thanks for the nice article with decent screenshots.
    Apart from the HKCU & HKLM, there are a few more Registry entries that pertain to Firefox. Here they are :

    [HKEY_CLASSES_ROOT\FirefoxHTML]
    [HKEY_CLASSES_ROOT\FirefoxURL\]
    [HKEY_CURRENT_USER\Software\Classes\Applications\firefox.exe]
    [HKEY_CURRENT_USER\Software\Mozilla]
    [HKEY_CURRENT_USER\Software\MozillaPlugins]
    [HKEY_LOCAL_MACHINE\SOFTWARE\Mozilla]
    [HKEY_LOCAL_MACHINE\SOFTWARE\mozilla.org]
    [HKEY_LOCAL_MACHINE\SOFTWARE\MozillaPlugins]
    [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Mozilla]
    [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\mozilla.org]
    [HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\MozillaPlugins]
    [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\FirefoxHTML]
    [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\FirefoxURL]

    Unfortunately, the reason I’m posting here is, I’m not able to find any registry key for the Home Page set in Firefox. Just like for IE8, we have something like START PAGE under this hive :

    HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main

    So, could you please share some insight on to this. I mean, if you can help me find the registry key for Firefox Start page similar to IE-7/8. I’d be highly grateful.

    Regards,
    Adam.

    • Firefox does not use registry keys to set things like the homepage.

      It can only be set via preferences or autoconfig files.

      You could write an add-on that read some of the registry entries and set them in Firefox…