Reducing Firefox Memory Usage

Filed in: Mozilla, Open Source, Tips n Tricks — April 20th, 2006

advertisement

Mozilla Firefox is a great web browser but it is not perfect. One of the common problems is that Firefox uses up a lot of system memory. Some say it is a memory leak problem. Anyway, here are a few things you could do to reduce Firefox memory usage.

Problematic extensions and themes

Firefox extensions and themes are cool but some can cause memory problems. Here are some tips on dealing with them:

  • Uninstall problematic extensions, including some popular extensions: Adblock, Fasterfox, FlashGot, and etc.
  • Uninstall any extensions and themes that you are not using.
  • Update extensions and themes to their latest version.

Memory hungry plugins

Some Firefox plugins can cause Firefox to use more memory than needed. Make sure you are using the latest version of every plugin. Tips in reduce memory usage for Adobe Reader and Shockwave.


Firefox Secrets : A Need-To-Know Guide

Clear Download history

If you keep a big download history, the Firefox memory usage can increase and cause Firefox to slow down or hang. It is advised to clear your download history and change the setting to clear download history upon successful download.

Change Download History setting

clear firefox download history upon successful download

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

Firefox secret settings

There are a few hidden Firefox settings that we can use to tweak Firefox memory usage. These settings can be set at about:config (type “about:config” at location bar, without quotes).

Note: Setting the wrong values may affect Firefox web browsing performance.

browser.cache.memory.capacity

  • description: set amount of cache memory
  • default value: -1 (dynamic, automatically decide based on total system memory)
  • tweak: set to a small value(in KB) to reduce Firefox memory usage.
  • more info: Browser.cache.memory.capacity

browser.cache.memory.enable

  • description: enable or disable cache memory
  • default value: true (enable)
  • tweak: set value to “false” to disable cache memory completely.
  • more info: Browser.cache.memory.enable

browser.sessionhistory.max_total_viewers

  • description: cache memory of recently visited pages for browser’s Back and Forward navigation.
  • default value: -1 (dynamic, automatically decide based on total system memory)
  • tweak: set a small value. “0″ for no store any pages in memory, “1″ for store one page in memory.
  • more info: Browser.sessionhistory.max_total_viewers

config.trim_on_minimize

  • description: release Firefox memory on minimized(MS Windows only).
  • default value: (this setting does not exist by default. We need to add it manually at about:config
  • tweak: add “config.trim_on_minimize”(boolean) at about:config, and set the value to “true”.
  • more info: Config.trim_on_minimize

The FINAL trick

Restart Firefox. Yes, this may sound stupid but it works for sure. :P

If you find Firefox’s memory usage grow after long periods of being used, it’s time to restart it. Bookmark all tabs as in folder or use session manager extension to save your current surfing pages.

My two cents

Firefox is one of my important blogging tools. I seldom close it, and it can take up to 200MB memory of my total 1.5GB(15000MB) iBook memory.

Personally, I DO NOT recommend you to change the Firefox settings at about:config, except config.trim_on_minimize. I think it is a good temporary solution for Firefox memory usage.

Too bad, the setting only works on Windows platform. So, I usually take the final trick — restart Firefox, about every 6 hours. :(

Let’s put our hope on upcoming Firefox 2.

Related book: Firefox Hacks : Tips & Tools for Next-Generation Web Browsing (Hacks)

[Source: MozillaZine Knowledge Base]

Bookmark and Share

Read also:

  • lmy
    try flock, which is based on mozilla also. i find that it doesn't take as much memory as firefox
  • LcF
    Flock is based on the same core as Firefox and it does not support Firefox extensions. If I want to give up those extensions, I would switch to Safari or Opera.
  • How bout IE7 beta2? What's you comment Liew?
  • LcF
    frankly, I haven't try IE7 yet. I am on Mac. However, I do not recommend to use Microsoft beta software for serious tasks. Also, I can't live without those handy extensions. That's the problem.
  • aMer
    Hey..Im confused..Is it "browser.sessionhistory.max.total.viewers" or "browser.sessionhistory.max_total_viewers" ?
  • LcF
    Sorry, my mistake. It is browser.sessionhistory.max_total_viewers
  • No matter what..Firefox is still the best browser out there imho.
    :)
  • great entry! Been having this firefox problem for ages but never came across a blog that talks about solutions.

    Out of all the suggestions you have, I only use the "Ultimate Method" - restart Firefox. It works best. I try not to let firefox memory grow more than 100,000k. (I'm computer nomad so most computer I use isn't very powderful)
  • I will choose to restart firefox too. IE7? I still can't trust MS buggy browser.
blog comments powered by Disqus