Firefox 67: automatically unload unused tabs to improve memory
Mozilla plans to introduce a new feature in Firefox 67 Stable that aims to improve the browser's memory usage in low memory conditions.
Browsers use a lot more memory than they did a decade ago, partly because websites grew significantly in size and partly because browsers changed as well.
It is not uncommon anymore that single tabs may use hundreds of Megabyte of memory, and there are cases where memory usage crosses the 1 Gigabyte mark for individual tabs.
Memory usage, especially on low memory devices, is a priority for browser makers. If you run Firefox or another browser on a 4 Gigabyte or 2 Gigabyte RAM system, you may experience a lot of caching if you open enough or the right kind of sites.
The concept of unloading tabs in the browser to free up memory is not a new one. Extensions like Dormancy, Suspend Background Tabs, BarTab, or Unload Tab for Firefox (all no longer compatible with Firefox 57 or newer), or Lazy Load Tabs, TabMemFree, or Tabs Limiter for Google Chrome, supported the functionality for years
Mozilla improved tab unloading significantly in recent years.
If things go as planned, Firefox 67 will introduce a new feature to unload unused tabs to improve memory. The initial bug report dates back eight years but work on the feature began in earnest just a short while ago.
Mozilla plans to unload tabs in Firefox in low-memory situations to reduce the number of crashes that users experience caused by low-memory. The bug lists another scenario, to free up resources, but it is not clear yet if and how this will be implemented.
Mozilla uses a simple priority list to determine which tabs to unload when the event fires (from lowest to highest)
- Regular Tabs
- Pinned Tabs
- Regular Tabs that Play Audio
- Pinned Tabs that Play Audio
The feature is already available in Firefox Nightly. It was turned on by default on my system but you can control it with the preference browser.tabs.unloadOnLowMemory.
True means the feature is enabled, False that it is disabled. It appears that it is available on Windows only at this point because its the only platform that Mozilla can detect low-memory conditions on according to the bug assignee Garbriele Svelto.
Firefox 67 will be released on May 14, 2019 to the Stable channel of the browser according to the release schedule.
Google implemented a similar feature in the company's Chrome browser. Introduced in 2015, Tab Discarding in Chrome discarded tabs from memory if system memory reached a certain threshold.
Mozilla expects a drop in out-of-memory related crashes in Firefox and plans to monitor these crashes in the coming weeks to test the hypothesis.
Now You: How much memory does your browser use, usually?