User Agents

Firefox Profile Location on Linux: Where to Find It

On Linux, Firefox stores your user profile in ~/.mozilla/firefox/ (a hidden folder in your home directory). Inside that folder, the active profile is the one whose name matches the entry marked (default) or (default-release) in profiles.ini—typically a folder with a random string like xxxxxxxx.default-release.

What Exactly Is a Firefox Profile?

A Firefox profile is not the same as your Firefox account. It is a local directory that holds everything that makes your browser feel like yours: bookmarks, history, saved passwords (encrypted), cookies, site permissions, extensions and their settings, custom preferences, downloaded files list, form autofill data, and the session store that lets you reopen tabs after a restart. Each profile is self-contained, so you can have multiple profiles on one Linux account—useful for separating work and personal browsing, testing a clean configuration, or keeping different language and privacy settings.

Firefox creates a default profile automatically the first time it runs. On Linux, that profile lives under your home directory, not in a system-wide location. The exact folder name is generated at creation time and is not meant to be memorable; the mapping between friendly profile names and folder paths is kept in a small text file called profiles.ini.

The Default Path and How to Confirm It

The standard location is:

  • ~/.mozilla/firefox/ — the parent directory for all profiles for your Linux user.
  • ~/.mozilla/firefox/<random-string>.<profile-name>/ — an individual profile folder.

Because ~/.mozilla starts with a dot, it is hidden in most file managers until you enable “Show Hidden Files” (often Ctrl+H in GNOME Files, Dolphin, and Thunar). In a terminal, ls -a ~ will reveal it.

The most reliable way to confirm which folder Firefox is actually using is through the browser itself:

  1. Open Firefox.
  2. Type about:support in the address bar and press Enter.
  3. Look for the “Profile Directory” row in the “Application Basics” table.
  4. Click “Open Directory” to launch your file manager at that exact path.

This works regardless of whether you have one profile or several, and it reflects the profile currently running—so it is the safest check before you copy, back up, or delete anything.

Reading profiles.ini to Map Names to Folders

The file ~/.mozilla/firefox/profiles.ini is a plain-text configuration file. It contains sections such as [Profile0], [Profile1], and so on, plus an [Install…] section that records which profile is the default for a given Firefox installation. Each profile section includes:

  • Name= — the human-readable name shown in the Profile Manager.
  • IsRelative=1 — meaning the path is relative to the ~/.mozilla/firefox/ directory.
  • Path= — the folder name, e.g. abc12345.default-release.
  • Default=1 — present on the profile that Firefox opens by default.

If you see multiple profiles, the one with Default=1 (or the one referenced by the Default= line in the [Install…] section) is the one Firefox uses on a normal launch. The others remain on disk until you remove them.

Why the Location Can Differ

While ~/.mozilla/firefox/ is the standard path, a few situations change it:

  • Snap or Flatpak packages. Firefox distributed as a Snap (common on Ubuntu) or Flatpak keeps its profile inside the sandbox, typically under ~/snap/firefox/common/.mozilla/firefox/ for Snap or ~/.var/app/org.mozilla.firefox/.mozilla/firefox/ for Flatpak. The internal layout is the same, but the parent path differs.
  • Custom profile directory. You can launch Firefox with -profile /path/to/folder to use a profile stored elsewhere. In that case, the folder is wherever you pointed it, and profiles.ini may not list it at all.
  • Different user account. Profiles are per Linux user. If you run Firefox as another user (or via sudo, which is not recommended), it will look in that user’s home directory.
  • Environment variable overrides. Setting MOZ_PROFILE_DIR or using a wrapper script can redirect the profile path, though this is uncommon for desktop users.

If you are unsure, about:support remains the ground truth because it reports the path Firefox is actively using.

Common Tasks and How the Path Matters

Knowing the profile location is useful for several routine jobs:

  • Backing up bookmarks, passwords, and settings. Copy the entire profile folder while Firefox is closed. The key files include places.sqlite (bookmarks and history), logins.json and key4.db (saved logins), prefs.js (preferences), and cookies.sqlite.
  • Migrating to a new machine. Copy the profile folder to the same relative path on the new system, then point Firefox at it via the Profile Manager or by editing profiles.ini.
  • Troubleshooting a broken browser. Renaming the profile folder (with Firefox closed) forces Firefox to create a fresh one on next launch—a quick way to tell whether an extension or setting is causing a problem.
  • Freeing disk space. Large profile folders often contain caches and old session data; clearing them is safer through Firefox’s own settings than by deleting files by hand.

A common misconception is that deleting the profile folder is the same as uninstalling Firefox. It is not: uninstalling the application usually leaves the profile intact, and deleting the profile removes your personal data even if the browser remains installed. Always back up before deleting.

Managing Multiple Profiles Safely

Firefox includes a Profile Manager, but on current Linux builds it is not exposed as a simple menu item. You can start it from the terminal with firefox -P (or firefox --ProfileManager), which lets you create, rename, and choose profiles. Menu labels and exact behavior can vary by Firefox version and by whether you are using the Snap or Flatpak build, so check the dialog carefully before confirming.

When working with profiles:

  1. Close all Firefox windows before copying or moving a profile folder.
  2. Keep a backup copy of the folder before renaming or deleting anything.
  3. Use about:support to verify which profile is active after changes.
  4. Avoid editing profiles.ini unless you are comfortable with plain-text config files; a malformed entry can make Firefox ignore a profile.

Also note that Firefox Sync is separate from the local profile. Sync stores a copy of bookmarks, history, tabs, and passwords on Mozilla’s servers, but the local profile remains the working copy on disk. Signing out of Sync does not delete the local profile.

Frequently Asked Questions

Where is the Firefox profile folder on Linux?

By default it is under ~/.mozilla/firefox/, inside a folder whose name ends in .default or .default-release. Snap and Flatpak installations use their own sandboxed paths, which you can confirm via about:support.

How do I open the profile folder quickly?

Go to about:support in Firefox and click “Open Directory” next to “Profile Directory.” That opens your file manager at the exact folder in use.

Can I move my Firefox profile to another location?

Yes. Close Firefox, move the folder, then either launch Firefox with -profile /new/path or update the path in profiles.ini. Keep a backup first, and verify the change with about:support.

Why does my profile path include “snap” or “.var”?

That indicates Firefox is installed as a Snap or Flatpak package. These packages run in a sandbox and store user data inside their own directories rather than directly in ~/.mozilla.

Is it safe to delete the profile folder?

It removes your bookmarks, history, passwords, extensions, and settings for that profile. Back it up first, and close Firefox before deleting. Uninstalling Firefox does not normally remove the profile.

Does the profile folder contain my saved passwords?

Yes, saved logins are stored in files such as logins.json and key4.db inside the profile. They are encrypted, but the folder should still be treated as sensitive and backed up securely.