Optimize SQLite Databases In Firefox

Martin Brinkmann
Jul 11, 2009
Updated • Feb 13, 2015

The Mozilla Firefox development team has changed the way the web browser stores information to SQLite databases in Firefox 3.

Cookies, Bookmarks, RSS feeds and many other information are now stored in SQLite databases that are stored in the Firefox profile.

A problem that can arise is that a database can get fragmented over time which inflates its size and can have the consequence that users on the system notice performance drops because of it. This happens for instance when Firefox attempts to pull data from a database for example.

It is possible to optimize SQLite databases to defragment them so that their size decreases performance bottlenecks are dealt with.

The website Web Upd8 explains how to optimize the SQLite databases of Firefox running under Windows, Linux or Mac OS. Windows users for example need to download a batch file and place it into the Firefox profile that they want to optimize.

The batch file will run the vacuum command on all SQlite databases that are located in the profile folder.

The effect of the optimization depends largely on the fragmentation of the SQLite databases.

Optimization on a test system reduced the size of the Firefox profile folder from 64.8 Megabytes to 53.4 Megabytes. Users with many bookmarks and RSS feeds will most likely see a large size reduction of the profile folder while users who use Firefox only occasionally will see little to no improvement.

Update: Places Cleaner is a free extension for Firefox that you can use to vacuum the Places database of the browser containing history and bookmark information. Once installed, tap on the Alt key and select Tools > Places Cleaner > Clean Now from the menu that opens up.

Mozilla suggests not to vacuum the database manually on the other hand.


Tutorials & Tips

Previous Post: «
Next Post: «


  1. Thufir said on October 14, 2014 at 6:00 am

    where are rss feeds stored, exactly?

  2. stream said on July 11, 2009 at 6:39 pm

    wow nice info. .thx

  3. paulus said on July 11, 2009 at 2:30 pm

    Really great find Martin this works, ferry well.

  4. xdmv said on July 11, 2009 at 1:00 pm

    Is there any way to limit the size of this databases?
    Thanks in advance!

    1. Martin said on July 11, 2009 at 1:03 pm

      There is no automatic way to limit the size. You have to do it manually.

Leave a Reply

Check the box to consent to your data being stored in line with the guidelines set out in our privacy policy

We love comments and welcome thoughtful and civilized discussion. Rudeness and personal attacks will not be tolerated. Please stay on-topic.
Please note that your comment may not appear immediately after you post it.