Skip to content

Common Overrides

yokoffing edited this page Dec 17, 2024 · 70 revisions

Instructions

  1. Open the user.js in a text editor such as Notepad.
  2. Add prefs from the options below.
  3. Save and close the file.
  4. Return to Required Reading.

Options

A user.js applies prefs in the order they are written.

So, if a pref is listed a second time, then the second value (yours) would override the first (Betterfox's).

my overrides section2

To enable certain functions, copy+paste the appropriate prefs to the MY OVERRIDES section of your user.js.


Font improvement

Firefox's text rendering on Windows is awful. This makes it better.

// PREF: improve font rendering by using DirectWrite everywhere like Chrome [WINDOWS]
user_pref("gfx.font_rendering.cleartype_params.rendering_mode", 5);
user_pref("gfx.font_rendering.cleartype_params.cleartype_level", 100);
user_pref("gfx.font_rendering.cleartype_params.force_gdi_classic_for_families", "");
user_pref("gfx.font_rendering.directwrite.use_gdi_table_loading", false);

Password, credit card, and address management

The built-in password manager is disabled for security.

  • → Settings → Privacy & Security → Logins and Passwords → Ask to save logins and passwords for websites

We recommend using Bitwarden or 1Password to manage your credentials on multiple devices.

// PREF: restore login manager
user_pref("signon.rememberSignons", true);

// PREF: pop-up to save logins for a new site
user_pref("signon.formlessCapture.enabled", true);

// PREF: restore address and credit card manager
user_pref("extensions.formautofill.addresses.enabled", true);
user_pref("extensions.formautofill.creditCards.enabled", true);

Location requests

Location requests are blocked to minimize annoyances.

Manage your site exceptions to allow only for websites you want to ask for your location.

  • → Settings → Privacy & Security → Permissions → Location
// PREF: allow websites to ask you for your location
user_pref("permissions.default.geo", 0);

Site notifications

Site notifications are blocked to increase security and minimize annoyances.

Manage your site exceptions to allow only for websites you want to send you notifications.

  • → Settings → Privacy & Security → Permissions → Notifications
// PREF: allow websites to ask you to receive site notifications
user_pref("permissions.default.desktop-notification", 0);

New tab shortcuts

Restore top sites

Top sites (pinned site shortcuts) are removed for a clean new tab page, but you can re-enable them.

  • → Settings → Home → Firefox Home Content
// PREF: restore Top Sites on New Tab page
user_pref("browser.newtabpage.activity-stream.feeds.topsites", true);

// PREF: remove default Top Sites (Facebook, Twitter, etc.)
// This does not block you from adding your own.
user_pref("browser.newtabpage.activity-stream.default.sites", "");

// PREF: remove sponsored content on New Tab page
user_pref("browser.newtabpage.activity-stream.showSponsoredTopSites", false); // Sponsored shortcuts 
user_pref("browser.newtabpage.activity-stream.feeds.section.topstories", false); // Recommended by Pocket
user_pref("browser.newtabpage.activity-stream.showSponsored", false); // Sponsored Stories

Alternatives

Weather widget

Firefox v.130 and later have the option to show Weather on the new tab page.

// PREF: show weather on New Tab page
user_pref("browser.newtabpage.activity-stream.showWeather", true);

Search settings

Allow search engine suggestions

Search suggestions are disabled in the URL bar to keep everything you type from going to Google.

  • → Settings → Search → Search Suggestions → Provide search suggestions
// PREF: restore search engine suggestions
user_pref("browser.search.suggest.enabled", true);

Change your default search engine

You can also select a default search engine just for Private Browsing windows. (This is an option after you apply the user.js and restart.)

  • → Settings → Search → Default Search Engine

Change your default search engine to DuckDuckGo, or add a premium search engine like Kagi.

For Kagi, if you want search suggestions in the URL bar, make sure to follow the first steps here. Then use the latter steps to setup Kagi for private browsing using your private session link. Otherwise, you can just use the private session link. Don't forget to add &q=%s to the end of the session link.


Containers

Enable container tabs if you want to login to the same site under different accounts.

You'll also want to install Multi-Account Containers for extra functionality (YouTube example).

// PREF: enable container tabs
user_pref("privacy.userContext.enabled", true);

Scrolling

Firefox's default scrolling could be better. Smoothfox provides options for a better scroll experience.

Important

Use only one option at a time! Reset prefs if you decide to use different option.