To install Firefox silently is easy. You just run the setup executable with a -ms parameter, for example: firefoxsetup.exe -ms
Deploying it with that parameter is a little more complicated but doable through scripts or management programs. Further more, if you would like to customize the default behavior of Firefox, it gets a little more complicated. Here are the steps I follow to create a customized Firefox that will be installed silently. The customizations I am making include:
- Disable import from other browser prompt at startup
- Set the homepage
- Disable prompt to send information back to Mozilla
- Disable showing “Firefox is open source software, know your rights” bar
- Disable checking if Firefox is default browser
- Disable “first run” tab
- Set bookmarks to autoexport to bookmarks.html file at shutdown
- Disable antivirus scanning on downloads
- Set Download directory
Things have changed since the Firefox Rapid Release schedule began. Instructions that used to work with Firefox 3 need to be updated to new locations in Firefox 4-15+. Searching online, many sites suggest using a batch script to copy files where they need to go. There’s actually no need for complicating the script if you know where to place the files.
In order to customize Firefox, I recommend having 7-Zip installed on your PC.
Download the latest Firefox setup executable from http://www.mozilla.org/en-US/firefox/new/ Right-click on the executable and go into Properties. Choose to Unblock the file if that is given as an option and hit ‘Ok’ to close out of the Properties Window.
Right-click on the Firefox executable again and go into the 7-Zip sub-menu, choosing “Extract to Firefox15”
In that new folder, browse to Firefox15coredefaults.
Create a new folder called profile.
Create a file called prefs.js
Edit the file to include the following lines:
# Mozilla User Preferences
/* Do not edit this file.
* If you make changes to this file while the browser is running,
* the changes will be overwritten when the browser exits.
* To make a manual change to preferences, you can visit the URL about:config
* For more information, see http://www.mozilla.org/unix/customizing.html#prefs
//Disable prompting to send information back to Mozilla
//Disable showing "Firefox is open source software, know your rights" bar
//Disable checking if Firefox is default browser
//Disable first run tab
//Set bookmarks to autoexport to bookmarks.html file
//Disable antivirus scanning on downloads
//Set Download directory
If you have Firefox installed on your machine already, you can create a new profile and customize the bookmarks how you would like them to appear. Then export the Bookmarks to an HTML file. Copy that file to the firefox15coredefaultsprofile folder so the user starts off with specific bookmarks.
In the firefox15coredefaultsprofile folder, you can create a folder called ‘searchplugins’. I then created a Search Plugin for my organization through www.searchplugins.net/generate.aspx and copied the resulting .xml file into the newly created searchplugins folder. Now users will start out with this search engine in their drop-down list.
Finally, I wanted to get rid of the Profile migrator that pops up when you start Firefox up for the first time. To do that, you create a file called override.ini and you place it in the firefox15core folder.
The override.ini file needs to contain this code:
Now all of our customizations are complete and they carry forward by default with newly created Firefox profiles. The Firefox first impression isn’t a great user experience in my opinion, so it’s nice to be able to improve it for your environment. To install Firefox silently with our customizations, we’ll just run a script that passes the silent parameter on the setup executable from the one we extracted.
With the ‘core’ folder also in the firefox15 directory, our customizations will be carried forward. It would be nice to be able to repackage the whole thing into a single executable again but I haven’t started looking into an easy, straight forward way to do that.