Modify Thunderbird settings: Difference between revisions

From MozillaZine Knowledge Base
Jump to navigationJump to search
No edit summary
 
(added a simpler set of instructions)
(27 intermediate revisions by 8 users not shown)
Line 1: Line 1:
Thunderbird stores any settings you created using tools -> account settings in the prefs.js file in your [http://kb.mozillazine.org/Profile_folder profile]. You can edit them using a text editor. You can also create a optional user.js text file in the same directory. Any settings you add to it will be merged into prefs.js by Thunderbird. Adding preferences via user.js helps to minimize the damage if you don't know what you're doing, and requires less knowledge.  
Thunderbird stores any settings you change or create using [[Menu differences in Windows, Linux, and Mac|Tools → Account Settings]] and [[Menu differences in Windows, Linux, and Mac|Tools → Options]] in the [[prefs.js]] file in the [[Profile_folder_-_Thunderbird | profile]].  


* The [https://addons.mozilla.org/extensions/moreinfo.php?application=thunderbird&numpg=10&id=17 ChromEdit extension] is a convenient way to add/modify preferences since it doesn't require you to know where your profile is stored. It will display the contents of pref.js and let you edit user.js. If user.js doesn't exist it will create it for you.
The recommended way to add or modify a setting which doesn't have its own input box, checkbox or radio button in said dialogs is to use [[Menu differences in Windows, Linux, and Mac|Tools → Options]] → Advanced → General → Config Editor, equivalent to Firefox's [[about:config]].  You can search for any preference using the filter field, and then double click on a preference to modify it. You can also add settings by right clicking anywhere in the list, selecting new from the context menu, and then select the type (string, integer or boolean), and enter the name of the setting and its value.


* The [https://addons.mozilla.org/extensions/moreinfo.php?application=thunderbird&numpg=10&id=423 About:Config extension] adds a tools -> about:config menu command. You can search for any preference using the filter edit field, and then double click on it to modify it. Thunderbird v1.4 (and later versions) includes this extension.
Some alternatives:


* There is also a [https://addons.mozilla.org/extensions/moreinfo.php?application=thunderbird&numpg=10&id=461 Preferential extension] you could use to modify Thunderbird's preferences but it appears to be browser-centric, and not as uptodate as About:Config.
#You can add or modify a setting by editing prefs.js directly using a text editor. However, prefs.js does not contain all of the settings, it only contains any settings that have changed. In fact, if you add a setting with a default value Thunderbird will quietly remove that line from the file the next time you run it. It is also not as tolerant of user errors as the config editor, and requires you to learn where the profile is stored. <p>Do not edit this file while Thunderbird is running since it may overwrite some of the settings when it exits, losing your edits.</p>
#The [https://addons.mozilla.org/en-US/thunderbird/addon/9695 ViewAbout] extension adds support for about:<something> windows just like those in Firefox. Its about:config window is the same as the Config Editor mentioned above.
#The [[ChromEdit]] extension makes it easy to edit prefs.js or user.js without knowing their location. It is no longer officially supported and you may have problems finding a version that works with future versions of Thunderbird.
#The [https://addons.mozilla.org/en-US/thunderbird/addon/421/ MR Tech Toolkit] extension, which is actively maintained, includes among others the functionalities of both ViewAbout and ChromEdit extensions mentioned above.


'''Example:'''
==Example==


If you have problems downloading a large message from a POP server or the the webmail extension doesn't fetch all of your new mail you may need to increase the value of the mail.pop3_response_timeout setting to keep Thunderbird from timing out. That setting defaults to 45 seconds. Thunderbird doesn't store a copy of default settings in prefs.js so you can't just edit it.  You can increase it to 180 seconds by adding: ''user_pref("mail.pop3_response_timeout", 180);'' to either prefs.js or user.js. You could also search for pop3 in the filter using tools -> about:config, find the entry for mail.pop3_response_timeout, double click on the value, and change it to 180.
You have a problem downloading a large message, or the webmail extension doesn't fetch all of your new mail. Increasing the timeout setting from the default 60 seconds to 120 seconds might help. However, the timeout setting, as with many preferences, cannot be set using the GUI. The first step is to figure out the name of the preference. If you can't find the preference in the knowledge base, try using the Config Editor to identify the name of the preference. If you type '''timeout''' in the filter you may see something like the following:


The defaults\pref\mailnews.js file in your thunderbird program directory contains most of the default settings. It uses a pref prefix rather than a user_pref prefix on any settings. For example, ''pref("mail.pop3_response_timeout", 45);'' . You should not edit that file. However, its sometimes usefull to view that file to find out what preferences exist and what are thier default values.
:accessibility.typeaheadfind.enabletimeout
:accessibility.typeaheadfind.timeout
:mail.server.server2.timeout
:mail.server.server4.timeout
:mailnews.tcptimeout
:network.ftp.idleConnectionTimeout
:network.http.keep-alive.timeout
:network.proxy.failover_timeout
 
along with their status, type and value. You need a preference whose name begins with mail or mailnews (it tends to have global settings). mail.server.server2.timeout and mail.server.server4.timeout are obviously server specific settings, network.* settings are normally too specialized (NTLM, dialup, cookie related settings etc.) and accessibility.* settings are clearly unrelated. That leaves the '''mailnews.tcptimeout''' setting. Double click on it, enter 120, and press the OK button. If you don't want to use the Config Editor you could have used a text editor to add '''user_pref("mailnews.tcptimeout", 120);''' to prefs.js instead.
 
The '''defaults\pref\mailnews.js''' file in your Thunderbird program [[installation directory]] contains most of the default settings. It uses a pref prefix rather than a user_pref prefix on any settings. For example, '''pref("mailnews.tcptimeout", 60);''' . You should not edit that file. However, it's sometimes useful to view that file to find out what preferences exist and what their default values are.
 
==Change connection timeout==
If you want to increase the connection timeout and the instructions in the example are too complex:
 
* Click on the Config Editor button in Tools -> Options -> Advanced -> General
* Type '''mailnews.tcptimeout''' at Filter:
* It should list the settings just for mailnews.tcptimeout.
* Look in the Value column and double click on that number. It defaults to 100 in Thunderbird 3.1.7.
* It should display a "Enter Integer value" window .
* Change the number to a higher value and press the OK button
* Verify the new value is listed in the Value column. The Status column should also change from "default" to "user set".
 
==User.js==
 
You can also create an optional [[user.js]] file in the same directory as prefs.js. It is mainly used by administrators to set the same settings in several profiles. It is recommended that you don't use it since any settings you add to it will be merged into prefs.js when Thunderbird starts, preventing permanent changes using the Config Editor.
 
==See also==
* [[About:config_entries | A list of many preferences that you can change using about:config]]
* [[about:config]] explains how to add settings using the Config editor. Normally you modify an existing setting.
* [[Editing_configuration | Editing configuration files]]
* [[Finding_the_profile_folder_on_Windows]]
* [[Mail_and_news_settings]]
 
[[Category:Thunderbird]]
[[Category:Configuration (Thunderbird)]]

Revision as of 04:58, 2 January 2011

Thunderbird stores any settings you change or create using Tools → Account Settings and Tools → Options in the prefs.js file in the profile.

The recommended way to add or modify a setting which doesn't have its own input box, checkbox or radio button in said dialogs is to use Tools → Options → Advanced → General → Config Editor, equivalent to Firefox's about:config. You can search for any preference using the filter field, and then double click on a preference to modify it. You can also add settings by right clicking anywhere in the list, selecting new from the context menu, and then select the type (string, integer or boolean), and enter the name of the setting and its value.

Some alternatives:

  1. You can add or modify a setting by editing prefs.js directly using a text editor. However, prefs.js does not contain all of the settings, it only contains any settings that have changed. In fact, if you add a setting with a default value Thunderbird will quietly remove that line from the file the next time you run it. It is also not as tolerant of user errors as the config editor, and requires you to learn where the profile is stored.

    Do not edit this file while Thunderbird is running since it may overwrite some of the settings when it exits, losing your edits.

  2. The ViewAbout extension adds support for about:<something> windows just like those in Firefox. Its about:config window is the same as the Config Editor mentioned above.
  3. The ChromEdit extension makes it easy to edit prefs.js or user.js without knowing their location. It is no longer officially supported and you may have problems finding a version that works with future versions of Thunderbird.
  4. The MR Tech Toolkit extension, which is actively maintained, includes among others the functionalities of both ViewAbout and ChromEdit extensions mentioned above.

Example

You have a problem downloading a large message, or the webmail extension doesn't fetch all of your new mail. Increasing the timeout setting from the default 60 seconds to 120 seconds might help. However, the timeout setting, as with many preferences, cannot be set using the GUI. The first step is to figure out the name of the preference. If you can't find the preference in the knowledge base, try using the Config Editor to identify the name of the preference. If you type timeout in the filter you may see something like the following:

accessibility.typeaheadfind.enabletimeout
accessibility.typeaheadfind.timeout
mail.server.server2.timeout
mail.server.server4.timeout
mailnews.tcptimeout
network.ftp.idleConnectionTimeout
network.http.keep-alive.timeout
network.proxy.failover_timeout

along with their status, type and value. You need a preference whose name begins with mail or mailnews (it tends to have global settings). mail.server.server2.timeout and mail.server.server4.timeout are obviously server specific settings, network.* settings are normally too specialized (NTLM, dialup, cookie related settings etc.) and accessibility.* settings are clearly unrelated. That leaves the mailnews.tcptimeout setting. Double click on it, enter 120, and press the OK button. If you don't want to use the Config Editor you could have used a text editor to add user_pref("mailnews.tcptimeout", 120); to prefs.js instead.

The defaults\pref\mailnews.js file in your Thunderbird program installation directory contains most of the default settings. It uses a pref prefix rather than a user_pref prefix on any settings. For example, pref("mailnews.tcptimeout", 60); . You should not edit that file. However, it's sometimes useful to view that file to find out what preferences exist and what their default values are.

Change connection timeout

If you want to increase the connection timeout and the instructions in the example are too complex:

  • Click on the Config Editor button in Tools -> Options -> Advanced -> General
  • Type mailnews.tcptimeout at Filter:
  • It should list the settings just for mailnews.tcptimeout.
  • Look in the Value column and double click on that number. It defaults to 100 in Thunderbird 3.1.7.
  • It should display a "Enter Integer value" window .
  • Change the number to a higher value and press the OK button
  • Verify the new value is listed in the Value column. The Status column should also change from "default" to "user set".

User.js

You can also create an optional user.js file in the same directory as prefs.js. It is mainly used by administrators to set the same settings in several profiles. It is recommended that you don't use it since any settings you add to it will be merged into prefs.js when Thunderbird starts, preventing permanent changes using the Config Editor.

See also