Java and Firefox memory usage

I have been using Sun’s old Java 1.5.0_06 runtime for quite a while, there simply wasn’t a good reason to waste time updating it. When investigating a Java-related crash I decided to check whether it will happen with a newer runtime (1.6.0-b105 was current at that time). Surprisingly, the crash disappeared even though this crash happened in Gecko code and not in the Java plugin.

But what I find more interesting is the change in Firefox’ memory usage I observe since that update. Previously Firefox would use 250 MB of memory after a few hours. It wouldn’t change much after that, only after a week or two the memory usage would climb to 350 MB. Now with a current Java version the usual numbers for Firefox are 150 MB reserved memory and below. After using it for over a week without restarting I still saw only 190 MB.

This is another indication that plugins have a huge impact on browser’s stability and memory use. So far extensions have received most of the blame, but usually they only cause crashes if they trigger bugs in Gecko or plugins. And thanks to dbaron’s Leak Monitor extension memory leaks in extensions have become rare.


  • tr

    What I often see is that plugin processes keep running after closing their tabs (e.g. Acrobat Reader). They’re still there after opening and closing dozens of tabs so I wonder whether there’s something one could do about those zombies.

  • pd

    Java causing problems? Never!

    Whether it me MS’s butchered implementation or Sun’s own plugin, Java is a horrible piece of software.

  • Joe

    Wow, I didn’t know that. Thanks!

  • Mook

    It probably doesn’t help that NPAPI isn’t exactly easy to use. We are, of course, stuck with it now.

  • Fox

    Foxit Reader is better than Acrobat Reader.
    And also, i think QuickTime Alternative *
    is much better than Official QuickTime

    * that site also has Real Alternative, but i have not used that or Official one much, i don’t need it.

    Only plugins i have are QuickTime (Alternative) and Flash , that’s it.
    (Foxit Reader is not plugin, is external program that opens .pdf files.)
    And yes, i have disabled Windows Media Player Plug-in,
    i did go to about:config and i did put very high number here:
    plugin.scan.WindowsMediaPlayer. So now Firefox does not use it.
    I did not have problems with that plugin, but now some sites just load little bit faster, and some sites have “download this video” -button, so i don’t miss much.

  • pirlouy

    Ah… Java…
    Developers are unanimous: it’s a great programming language, easier to learn, to use, object-oriented programming is wonderful, etc.

    Unfortunately, users are unanimous too: each time a software launches Java Virtual Machine, it’s a nightmare…
    Personally, each time a site uses java, I know I’ll have to close browser ASAP.

    Don’t know who is the most responsible, Sun or Mozilla… or nobody.

    Wladimir Palant

    Java is a great language – just not for the web.

  • rick752

    “Java is a great language – just not for the web.”

    Amen, my friend. I cringe at the clicking of my hard drive after the whole page has loaded just knowing that the ‘coffee cup’ is going to appear in my tray. God help should you hit the ‘back’ button right in the middle of one of those ‘god for saken’ an applet loads in Firefox …. I think that that mistake has been my only cause of crashes ever with Fx.

    There are so many more ‘web friendly’ type scripts to replace java over the years. I really don’t know why anyone uses that on the web anymore :-(

    Wladimir Palant

    Actually, that seems to be mostly Firefox’ fault. Firefox 3.0 alphas can handle Java much better.

  • IceDogg

    This must be why I don’t have as many problems with Firefox as others complain about, I never use Java. IMHO no need.

  • Bambo

    Well it is also not used that many places. About the only site I see it kick in is when logging in to my banks Homebanking section. Takes care of security and I dont mind it.

    Besides that Java on the web has gotten better – or computers faster, heh. Both perhaps.

    Not a good reason to update Java? I think there is. Ok they still push 1.5x but as with Firefox newer is almost always better.

    Wladimir Palant

    It is hardly used anywhere on the web – and that’s exactly the reason why I didn’t see much point in upgrading. I still use JDK 1.5 for programming and I don’t need a runtime that is newer for that either. Actually, no homebanking application I used required Java, all of them are happy with SSL + JavaScript. The only web page with Java that I sometimes use is but I usually prefer Google Maps.

  • Oldtima

    AH! I just remembered why I initiatly downloaded this Java crap in the 1st place: LIMEWIRE!!!!!

    Everybody here who has for one reason or another forgotten why they installed Java and deduced it to a site that you probably really wanted to visit and view content on… might have to see if you have Limewire installed.

    I know millions alone have Java installed for this very reason alone as the application will not run without it.

    I wonder when Limewire flops, so will Java downloads? Bahahahahaa.

  • Simon

    It’s the same with all the applications! with LimeWire Pro my the downloads were so (so so so so… ouch) slow, I saw this freaking tip of the day (whatever it called) and it says that LimeWire will work faster and will be more stable with the latest java runtime environment… true true the app itself works now faster and so are the search speed and my DOWNLOAD speed (I think 5 times faster, if not more!!)


  • Simon

    Oops! didn’t notice pots No.10 by Oldtima. Well I guess Oldtima proved his/her point! (tima is a boy as far as I know)

  • interneter


    Wladimir Palant

    Not an update, an absolutely unrelated issue.