Reducing Memory usage in Firefox

I have been using firefox browser for a while now. Although I never had any issue with this browser, I just hate it when it starts hogging on memory and eats up almost half of the RAM.

Following are few tweaks that you can perform on your firefox browser to reduce its memory usage.

1. Remove unnecessary Add-ons and Themes

One of the primary reasons of Firefox slowing down is due to large number of installed extensions. We are tempted to try out each and every fancy add-ons and these could slow down Firefox. Few things to take care while installing and using add-ons

  • Uninstall all add-ons which are not used
  • Install only the latest versions of add-on.
  • Remove unnecessary scripts and themes.

You can also check Firefox memory usage by opening Firefox in safe mode by disabling all add-ons. To open in Safe mode, either you can select it from the programs menu or type firefox -safe-mode in run command.

2. Clear Download History

Memory usage can increase and Firefox can slow down or hang if the download history is allowed to accumulate. Clear the download history (you may need to exit Firefox and delete the file “downloads.rdf” from the profile folder in some cases) and change this setting to circumvent the problem:

Tools -> Options -> Privacy -> Download History -> Remove Files from the Download Manager, select: “Upon successful download”.

3. Reduce memory usage when minimize

Firefox comes with an option by which we can configure Firefox to reduce its memory usage when it is minimize. Following is the procedure to configure firefox to release memory when minimized.

  1. Type in about:config in the address bar and hit Enter
  2. Right click and choose New > Boolean
  3. Type config.trim_on_minimize in the pop-up box and hit Enter
  4. Select True and hit Enter.
  5. Restart Firefox

4. Fixed cache capacity or Disable Cache Totally

Every time new page is loaded, Firefox will cache the page so it doesn’t need to load again to be redisplayed. By default, this setting is set to -1 for browser.cache.memory.capacity and to a number you specified in Tools -> Options -> Advanced -> Network / Cache for browser.cache.disk.capacity

To fix your cache to a certain value the browser.cache.memory.enable and browser.cache.disk.enable needs to be True for this to work

  1. Type about:config in the address bar and hit Enter
  2. Search for browser.cache.memory.capacity and set a number in KB to use for the memory cache (ie. 1024KB = 1MB)
  3. Search for browser.cache.disk.capacity and set a number in KB to use for the disk cache (ie. 1024KB = 1MB)

To Disable the cache Totally

Set both browser.cache.memory.capacity and browser.cache.disk.capacity to 0.

Alternatively, you can also set browser.cache.disk.enable and browser.cache.memory.enable to False.

5. Restarting Firefox

If you are using Firefox for long hours, then its advisable to restart Firefox periodically as Firefox memory usage increases when kept open for long hours. You can use the session restore feature in to bring back all the windows after restart.

View Comments

  • Good info but I wouldn't recommend turning off the browser cache. It will slow down page load noticeably. FF cache stores small files (images, css, js) individually and reuse them in the subsequent requests. Memory cache can reduce page load time a LOT if a HTML includes the same image (say space.gif) over and over.

Share
Published by
Viral Patel
Tags: browsers Firefox tips & tricks

Recent Posts

  • Java

Java URL Encoder/Decoder Example

Java URL Encoder/Decoder Example - In this tutorial we will see how to URL encode/decode…

4 years ago
  • General

How to Show Multiple Examples in OpenAPI Spec

Show Multiple Examples in OpenAPI - OpenAPI (aka Swagger) Specifications has become a defecto standard…

4 years ago
  • General

How to Run Local WordPress using Docker

Local WordPress using Docker - Running a local WordPress development environment is crucial for testing…

4 years ago
  • Java

Create and Validate JWT Token in Java using JJWT

1. JWT Token Overview JSON Web Token (JWT) is an open standard defines a compact…

4 years ago
  • Spring Boot

Spring Boot GraphQL Subscription Realtime API

GraphQL Subscription provides a great way of building real-time API. In this tutorial we will…

5 years ago
  • Spring Boot

Spring Boot DynamoDB Integration Test using Testcontainers

1. Overview Spring Boot Webflux DynamoDB Integration tests - In this tutorial we will see…

5 years ago