This script will clean-up Mozilla Firefox History (Crash, Telemetry and Profile lock files, DOM Storage, Cookies, Site-specific preferences, Saved form data, Autocomplete history) and optimizes and shrinks all sqlite files.
Extract the complete archive (including sqlite3.exe) to the Scripts folder of Cleanmgr+
SQLite is a software library that implements a self-contained, serverless, zero-configuration, transactional SQL database engine. Mozilla Firefox store its history in a file called places.sqlite in the Profile folder. You can directly manipulate the SQLite database and also optimize/shrink it or let Cleanmgr+ do this for you.
More information about the places.sqlite can be found here.
CloneApp is a free and portable program for Microsoft Windows devices to back up preferences, settings and other data of supported applications. CloneApp is highly customizable and can a be extended via "plug-ins", plain text files which define exactly which files, folders and Registry keys the program should preserve.
It requires Windows 10, 8.1, 8, 7 or Vista, including both 32-bit and 64-bit versions.