I recently discovered that Mozilla has been shipping AI in Firefox. If you are okay with AI in your Firefox, you can likely ignore this blog post.
Otherwise, here are some steps I took to permanently keep settings locked to disable the AI stuff in Firefox.
First off, I run Firefox in ~/firefox/fx-stable/. This is where I un-targzip my Firefox installation. I don't compile it. I just run the pre-built binary from Firefox's website.
Secondly, I use the default path for Firefox profiles: ~/.mozilla/firefox/. This is where Firefox stores profiles by default on Linux.
To get started:
- Create a file called
local-settings.jsin your Firefox installation/run directory in the subdirectorydefaults/pref/, for me it is:~/firefox/fx-stable/defaults/pref/- It should be the same place the
channel-prefs.jsfile is located, if that helps.
- It should be the same place the
- In this file put:
pref("general.config.obscure_value", 0); // only needed if you do not want to obscure the content with ROT-13
pref("general.config.filename", "mozilla.cfg");
- Create a file named
mozilla.cfgin your Firefox installation/run directory, for me it is:~/firefox/fx-stable/ - In this file put, (note the extra space at the top, if you put the
lockPrefon the first line, Firefox seems to ignore it):
// lock preferences
// extra space
lockPref("browser.ml.enable", false);
lockPref("browser.ml.enabled", false);
lockPref("browser.ml.chat.enable", false);
lockPref("browser.ml.chat.enabled", false);
lockPref("browser.ml.chat.menu", false);
lockPref("browser.ml.chat.page", false);
lockPref("browser.ml.chat.page.footerBadge", false);
lockPref("browser.ml.chat.page.menuBadge", false);
lockPref("browser.ml.chat.shortcuts", false);
lockPref("browser.ml.chat.shortcuts.custom", false);
lockPref("browser.ml.chat.sidebar", false);
lockPref("browser.ml.linkPreview.shift", false);
lockPref("browser.ml.linkPreview.enabled", false);
lockPref("browser.ml.pageAssist.enabled", false);
lockPref("browser.tabs.groups.smart.enabled", false);
lockPref("browser.tabs.groups.smart.userEnabled", false);
lockPref("extensions.ml.enabled", false);
- Then launch Firefox
- Go to
about:config, and search for any of the values listed in themozilla.cfgfile. - Verify it is set to false and it is in italics, with a lock symbol. This means it can't be changed.
If you need to update or remove a value at a later time, just edited the mozilla.cfg file and restart your Firefox process.
This was heavily borrowed from: https://kb.mozillazine.org/Locking_preferences
Happy Firefoxing!
