Search Support

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More

Prevent Firefox from Clearing the Cache Automatically

  • 4 replies
  • 1 has this problem
  • Last reply by Phil B.

more options

Hi all,

I'm a photographer and I've been using Firefox as my default/go-to browser for dealing with images-related things like uploading and downloading to server, accessing and opening photography-related sites and accounts such as Flickr Pro. I'd like to know if any of you can help me with my problem with cache.

So I've noticed that when using Firefox, oftentimes the cache is being cleared/purged automatically, for reasons I don't know yet. I'd like to know how I can keep the cache, or in other words, prevent Firefox from clearing the cache for any reason whatsoever. I really need the cache and I don't mind keeping a large or even massive cache. I'm browsing the same sites over and over again and I'd like to keep the cache instead of having to download it again everytime I browse the sites with Firefox.

The problem is I've tried things like disabling smart cache size and increasing my disk cache to 4 GB to no avail. Firefox always clears the cache automatically after certain period of time or under certain or specific condition(s). The thing is I don't know how to stop Firefox from tampering with my cache. None of my add-ons is actually tampering with the cache, nevermind clearing it.

Several settings that I've changed/modified manually:

・ browser.cache.auto_delete_cache_version: set to -1.

・ browser.cache.check_doc_frequency: set to 2.

・ browser.cache.disk.capacity: set to 4096000. I read somewhere that a Firefox users and a fellow photographer managed to increase the size to 16 GB with his Firefox 69 and is able to keep his cache until he clears it manually, but I failed to repro his steps since my Firefox always reverted back to 380 MB or something whenever I did that. He's probably using custom userChrome and/or userContent css.

All these settings are set to false: ・ browser.cache.disk.smart_size.enabled ・ browser.cache.disk.smart_size.first_run ・ browser.cache.disk.smart_size.use_old_max

・ browser.cache.memory.capacity: set to 2048000.

・ media.cache_size: sometimes I set this to 4096000 to see if it helps with anything, but most of the time it is set to its default value (unchanged).

・ browser.tabs.remote.warmup.enabled: set to false. I might accidentally added this to my 56.0.2 (and set it to false) since I don't remember tab warming being in pre-Quantum, but my 69.0.2 has this and I set it to false. There is also a thing with mouse cursor hovering over a tab making it reload the tab, but only after Firefox clear my cache.

If any of you curious about why I'm using 56.0.2, it's because I'm still using Multi Paste and Go add-on, which is a Godsend to me. It's really helpful with accessing or opening several links or images at once, oftentimes more than 30-40 images, and unfortunately the add-on is not made compatible with 69.0.2. I'm a very careful person when it comes to security and I never opened any sites with questionable or suspicious quality, just things related to work (photography) and bills (So-Net Nuro, Softbank, etc.) so please don't worry about my browsing habits or security risks. I also always disable Flash plugin.

At this point, I really have no idea how to prevent Firefox from clearing my cache. Sometimes Firefox clears my cache when I am still browsing, sometimes when I leave it idle. Sometimes I can reach over 1 GB of cache size before Firefox clears it, sometimes Firefox clears the cache when the size is still about 100-200 MB.

I always perform system maintenance manually (from updating OS to installing drivers, from setting up Adobe Photoshop and Lightroom to making backups) so I'd rather clearing my cache manually instead of letting Firefox do that for me.

Can any of you help me with my problem with cache?

I appreciate and thank for the help, advice, suggestion and assistance you could provide. I don't mind using custom userChrome or userContent as long as you don't mind guiding me with it (I never used it before).

I'm looking forward to get your help and feedback. Thank you very much.

Jun T.

p.s. while I can read English, I'm Japanese and I can't speak or write English fluently like a native speaker, so please forgive me if there's any typo or grammatical error in my explanation.

Modified by Jun

All Replies (4)

more options

Hi Jun, I don't know if it was still true in Firefox 56, but back in the day, Firefox would clear the cache in case of an abnormal shutdown, such as a crash. That's very hard to avoid; perhaps you never have that issue.

I can't think of a reason that Firefox would clear your cache in the middle of a session. Some items may expire naturally because the server set a short expiration time, but others should linger nearly indefinitely until bumped to make space for something new.

So I guess I can't help, because what you're describing doesn't sound normal.

I'm sure there's a replacement for Multi-Link Page and Go, but most likely you would need to paste into an extension's dialog box instead of into a new tab.

more options

This one should work if your URL lists are tidy:

This one sounds similar to the one you were using before, but the reviews aren't as good:

more options

Hello, thank you very much for the suggestion.

I use 56.0.2 for most of my photography-related browsing such as opening sites or uploading/downloading images, and 69.0.2 for photography and formal/business/billing such as email and managing memberships/subscriptions/accounts.

I'm fine with Multi Paste & Go in 56.0.2, but nevertheless, thank you very much for the suggestion. I'll keep the add-on in my note in case I need to use Quantum for photography-related browsing.

Regarding the automatic cache cleaning in the pre-Quantum period, I'm aware about that. Firefox used to clean the cache whenever the browser shutdown is marked as unclean, such as when a user forgets to close Firefox before shutting down or restarting Windows or crashes like BSOD or sudden shutdown due to power loss or outtage.

But my problem here is not about unclean shutdown, but rather Firefox that mysteriously and automatically clear my cache without my knowlegde, permission or concern, usually after certain period of time, under specific condition I have yet to know about or when or if certain size (of cache) is reached.

I have heard from fellow photographers, both from Japan and overseas, that this is the long-running issue in Firefox, and that, they thought, might actually be the feature of Firefox instead of a bug or flaw.

If that's the case, then I really need to disable it. While I have unlimited data cap and very fast connection when I'm at home (in Tokyo), I don't always have unlimited data cap and fast connection when I'm working for photography projects anywhere else, especially overseas. Having my cache intact and my browser not tampering with it can be extremely helpful during times when data cap is limited and speed is slow, especially when I'm accessing my own cloud storage and managing images or opening sites like Flickr Pro. I really appreciate if the browser never tamper or even clear my cache and make things unnecessary difficult for me.

Even with my unlimited data cap and very fast internet at home, I honestly admit this issue annoys me a lot.

If anyone, especially engineers from Mozilla can help me with this frustrating issue, please help me. I apologise if I sound like impatient, but I've been struggling with this cache issue and I have yet to find a solution to it.

Once again, I appreciate and thank everyone willing to take their time to help me with this issue.

I'm looking forward to hear from all of you.

Jun T.

more options

Hi,folks. When the cache in my Firefox-70 reaches 150MB the viewing of online video (YouTube, var. news outlets, etc) comes to a halt. The cache must be manually cleared to resume. Ubuntu 18.04.3/16GB mem/AMD Quad/1TB HDD.