4

Firefox and firefox-esr can be configured on Linux Mint 21 Cinnamon, in the following ways, for example, but possibly not exclusively:

via GUI
via about:config
policies.json
user.js
and possibly about other files

Differences in the effect of a selected configuration type can exist, for example, in that they apply system-wide, only for a specific user or only for a specific Firefox profile.

Question:

  • Which configuration files can be used to configure Firefox and Firefox-esr?
  • In which folders are these stored?
  • For which users of a system are these configuration files effective, depending on the chosen storage location?
  • What is the behavior if there are contradictory configurations in different configuration files, which ones then have priority ?
1
  • 1
    This question currently includes multiple questions in one. It should focus on one problem only! Commented Dec 10, 2022 at 17:32

2 Answers 2

6
+50

Firefox can be configured in both file and non-file based ways.

Configuration options on non file basis:

  • via the GUI of Firefox which can be accessed either via:

    Firefox--Menu bar --Edit--Settings

or via the browser line via:

about:preferences 

The configuration will be saved on:

prefs.js

Dont edit this file by hand. Do it only by the way above.

  • a further and more extensive possibility than the before mentioned, exists over the browser line, over the call:

    about:config

The above configurations are only valid in the FF profile in which they were made and are overridden by user-wide and even more so by system-wide defaults. They are also only of limited use, since they are not protected against changes by users, Mozilla or unfriendly software.

A file based configuration is possible through the following files:

user.js , you can edit by hand, changing will be added by next FF start on prefs.js

policies.json , this file can be edit by hand

The file locations are for a system-wide configuration:

/etc/firefox/policies/policies.json

For one that is limited to the user, they are:

/etc/firefox/profilename/prefs.js

If you have installed Firefox or Firefox-esr and what the installation location is called, you can use the following query:

whereis firefox

whereis firefox-esr

If you don't use Firefox but the more configurable Firefox-esr, swap the two following entries in in the examples above:

firefox
firefox-esr

If you see potential to improve the answer, feel free to edit and improve it.

1
  • how about the "or" case ?
    – Alfred.37
    Commented Dec 15, 2022 at 22:38
-2

Firefox and Firefox ESR (Extended Support Release) can be configured on various configurations files and methods:

GUI

The easiest way to configure Firefox is through the graphical user interface (GUI). You can access the configuration options by going to the menu (the three horizontal lines in the top-right corner of the window), selecting "Preferences" and then navigating to the settings you want to modify.

about:config

You can access advanced configuration options in Firefox by typing "about:config" in the address bar and pressing Enter. This will open a page with a list of advanced configuration options that you can modify. Note that some of these options may be experimental or unsupported, and changing them may have unintended consequences.

policies.json

The policies.json file is used to configure Firefox using Group Policy Objects (GPOs) on Windows systems. On Linux systems, you can use the policies.json file to configure Firefox system-wide or for a specific user by placing the file in the appropriate location.

For system-wide configuration, you can place the policies.json file in the /etc/firefox/ directory. For user-specific configuration, you can place the policies.json file in the ~/.mozilla/firefox// directory, where is the name of the Firefox profile.

user.js

The user.js file is a script that is used to configure Firefox when it starts up. You can use the user.js file to set default values for advanced configuration options that are not exposed in the GUI or about:config page.

You can place the user.js file in the ~/.mozilla/firefox// directory to apply the configuration to a specific Firefox profile. You can also place the user.js file in the /etc/firefox/ directory to apply the configuration system-wide.

Other files

There are several other configuration files that can be used to configure Firefox, such as prefs.js, autoconfig.js, mozilla.cfg, and local-settings.js. These files are typically located in the ~/.mozilla/firefox// directory or in the /etc/firefox/ directory, depending on whether they are intended to apply to a specific Firefox profile or system-wide.

Priority

If there are contradictory configurations in different configuration files, the priority of the configuration files is as follows:

  • policies.json
  • mozilla.cfg
  • autoconfig.js
  • local-settings.js
  • user.js
  • prefs.js

This means that configurations in the policies.json file will take precedence over configurations in the mozilla.cfg file, and so on. Configuration options set through the GUI or about:config page will take precedence over all other configuration files.

1
  • 4
    The fact that it is well written, uses markdown correctly to do certain markup of the text, but fails to correctly mark up pathnames, tells me that this text is generated by an AI, just like the other answers posted by this user within a short window of time. The answer follows the usual ChatGPT answer template.
    – Kusalananda
    Commented Dec 19, 2022 at 14:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .