PowerUOC Project. Link to alternative TenFourFox tweak project.
Legacy Addon Site <--- Note, closed on December 2019. Try this link: https://web.archive.org/web/20191110142013/https://legacycollector.org/firefox-addons/index.html
@Altemose Easy Installer
My personal prefs file from my Intel Mac. I am providing this here because the one below this one tends to cause a wierd graphics glitch on non-PowerPC Macs and PCs. This prefs file was created from scratch starting with Hack5190's clean prefs file and clean installation of my addons. Rename this file to "prefs.js" (without the quotes) and install in the usual directory. It can be edited with a text editor to remove my addon data if you wish.
My personal prefs file. Note, I am using disk caching to a ram disk and my prefs will reflect this. If you want that, either modify the file path or delete this pref in about:config: browser.cache.disk.parent_directory
**UPDATE 02.09.2019** Hack5190's JS file is no longer on Dropbox (per below). @Lastic has provided a new link to the same file. Now located in Post 355
<==========> The above will be for quick linking to the various methods of getting these tweaks. Below this line will be continued edits. <==========>
Post 171 Hack5190's user.js option. Apply all changes mentioned in this thread (up to post 165) while keeping your own preferences file.
@Hack5190 Clean Prefs file with all my tweaks
EDIT 7.6.19: REMOVING TELEMETRY AND DATA COLLECTION TO INCREASE SPEED. See post 382.
EDIT 3.5.19: Updated edits to the following: Post #363
Also, uMatrix 1.1.4 may be found here: https://github.com/gorhill/uMatrix/releases?after=1.1.6
EDIT 9.30.16: Updated edits to the following:
EDIT 4.18.16: Edit to include above quicklink section and add in @Hack5190's Clean Prefs install. Hack's prefs file contains all my tweaks with none of my preferences for addons that I've generated over the years.
The ‘Clean prefs.js’ file eyoungren linked in post #1 started with a virgin prefs.js file in a fresh TenFourFox install on my PowerBook G4. Working with eyoungren the virgin file was edited to include all the speed and security tweaks contained in the first 149 posts of this thread.
The linked file is a zip file that contains both the virgin prefs.js and modified prefs.js files.
Please note that this may be a solution to try for those of you who are using my tweaks file on Intel Mac/PC/Linux boxes that have the pink graphical glitch in the upper left hand corner.
It's been suggested that I might start from a fresh file and add in all my tweaks. This would be a lot of work for me, not least because over the ten or more years this file has been in existence I'm not sure what is or is not relevant. So, I err on the side of caution by leaving stuff I cannot identify as belonging to this or that addon in place. Further, it was never my intention to provide a completely clean copy of prefs.js with only my speed/network modifications applied. The original intention of this thread was for you, the user to apply them to your own personal copy.
I can also see some sort of three file maintenance here. One clean copy, one clean copy with only my tweaks applied and MY personal copy (cleaned up). That's not something I wish to keep track of, although if anyone is willing to do this beyond what Altemose provides I'm certain he'd welcome the help.
@Altemose's Easy Installer was the middle ground between all of this as Altemose DID intend to start from scratch while I intended (and still do) mainly to maintain a running thread of tweaks as I find them. I will continue to do so as I am sure Altemose will continue to maintain his thread.
EDIT 2.13.16: I was thinking a little bit today and I have decided to post a direct link to my current prefs file. The difference between my file and the Easy Installer that @Altemose provides is that Altemose is making certain choices about what to include to give a good balance among all PowerPC Macs. The file I am providing is the actual one I use everyday and it has all the extreme tweaks I've made.
File goes here: ~username/Library/Application Support/Firefox/Profiles/Your Profile/
Use at your own risk: https://dl.dropboxusercontent.com/u/1932210/prefs.js <--- Right click and download the link, otherwise it will load as text in the browser.
I would suggest removing the previous prefs.js file and placing some place safe in case you wish to revert. Otherwise you will be asked to overwrite the file.
*NOTE* I've been asked a few times about these tweaks in reference to Firefox on Mac Intel or PC machines. Since TenFourFox is based on Mozilla (it shares the same code) anything you get out of this thread can also be applied to Firefox on any platform. about:config is the same on Mac (Intel or PowerPC), PC and Linux. So, if you want to apply this to Firefox on your MBP or your PC box go right ahead. It will work.
ADDITIONS, September 16, 2015. Courtesy of user jbarley. Mainly deals with animations in the browser interface.
Originally found here on LowEndMac.
nglayout.enable_drag_images to false. This makes dragging images faster by showing a thin frame instead of the complete (transparent) image.
browser.preferences.animateFadeIn to false. This prevents resizing and fading-in of the content when switching tabs in the preferences pane. Native OS X menus do this with better performance, but the Firefox/TenFourFox XUL interface isn’t quick enough to make it enjoyable on slower Macs.
browser.tabs.animate to false. This way, creating and closing tabs will be instantly. And no more “Assertion Failed. Giving up waiting for the tab closing animation to finish” messages.
browser.fullscreen.animateUp to 0. This prevents the unnecessary and sometimes slow animation when switching to full screen. Alternatively, you can set browser.fullscreen.autohide to false; this leaves the navigation bar always visible.
browser.panorama.animate_zoom to false. This gives you an instant switch from tab groups to normal windows.
image.animation_mode to once (or None). This will prevent GIF animations from looping (or playing at all), thereby reducing processor load (especially on Tumblr), and letting you read text undistracted by blinking stuff in the corner of your eye.[/b]
EDIT 9.3.15: The Mozilla website for Firefox addons has an optimization addon that covers some of the following tweaks. If you prefer a graphical interface over mucking around inside about:config then this addon may be right for you. It gets the important stuff but does not cover some of the fine tuning that this guide and Altemose's easy installer covers.
EDIT 8.11.15: Altemose maintains a prefs file comprising most (if not all) of the tweaks in this thread. If you'd rather just install that and be done with it click here.
EDIT, January 17, 2015: One other helpful thing is garbage collection. If you go to about:memory there will be an option there under Free Memory to reduce memory usage. Click on that and you will get ram back.
Another thing that is helpful is to use the Purge command in Terminal. This requires the developer tools to be installed (the purge command is not there by default), but it will also release memory back to the system. Do note, that T4FX may be a bit sluggish after using the purge command (especially if you have not done garbage collection in the browser beforehand) but will pick up in a short while.
That said, there is one camp here that believes that the purge command is detrimental because it also clears some other things not just ram. I've found it to be very useful, but others here believe it's not.
Just giving you the two sides on that.
EDIT 2, January 17, 2015. Edited the following:
Changed from 400 to 200. Seems to be a better value.
EDIT 3, January 17, 2015. Two more…
NOTE: I AM ASSUMING A CERTAIN LEVEL OF KNOWLEDGE ABOUT THE BROWSER AND THEREFORE THAT THE READER UNDERSTANDS HOW TO ACCESS ABOUT:CONFIG AND MAKE THE APPROPRIATE CHANGES THERE AND HOW TO CREATE A SETTING IF IT IS NOT PRESENT. IF YOU DO NOT KNOW HOW TO DO THIS, IT IS EXPLAINED IN FURTHER POSTS, BUT I WOULD SUGGEST READING UP ON FIREFOX AND ABOUT:CONFIG.
Well…at long last, the promised write up.
Here is every modification I've made that matters. Writeup starts below.
This guide to my optimizations for TenFourFox is in two parts. Part I deals with the extensions that I use specifically to help speed up TenFourFox and Part II deals with the about:config settings I use.
I will explain as best as possible each extension/setting. Note that some settings that I mention are deprecated or no longer used, but are still in my config file. If you do not have a setting I list you have the option of creating it anyway and applying it. If it's deprecated it won't affect anything.
You do not have to use my settings. You can set whatever you want for what you are comfortable with as long as it's in the parameters of the setting. My settings are extreme and designed to make a PowerBook G4 with a failed external cache perform as well as possible.
My profile has existed through several browsers for several years so there is bound to be some clutter.
I take no responsibility for tanking your profile or messing up TenFourFox, so follow this guide at your own risk.
Part I: Extensions:
Block Site 1.1.8 - Automagically blocks websites of your choice. I use this extension to directly block any site I don't want the browser to load. For instance, Google News has a tendency to load images from YouTube. That tends to stall my version of T4Fx, so I have ytimg.com blocked and the browser doesn't even try to load from there. Note, I am no longer using this tweak as it has been replaced by the functionality of uMatrix.
Bluhell Firewall 2.5.0 - Lightweight Ad-Blocker and Tracking/Privacy Protector. I use this instead of ABP or ABE because it's light and it has no memory leaks. So far I have yet to see any ads.
google-no-tracking-url 1.3.1 - It simply removes tracking code/redirect from Google search results. Pretty simple. Note, I am no longer using this tweak as it has been replaced by the functionality of uMatrix.
NO Google Analytics 0.6 - Blocks Google Analytics. Simple, kills Google Analytics, one of the most CPU intensive hidden parasites that websites load in the background while you aren't watching. As a user I hate analytics. Note, I am no longer using this tweak as it has been replaced by the functionality of uMatrix.
QCLean - Remove Facebook Ads Suggested Pages and Posts 0.4 - Remove Ads, Suggested Pages and Posts on News feed of Facebook. BluHell Firewall doesn't seem to work with Facebook, so I use this extension specifically for Facebook. With ads killed, FB loads faster. I have removed this as it seems I am spending less and less time on FB and uMatrix seems to accomplish some blocking here when I do use FB.
RefControl 0.8.17 - Control what gets sent as the HTTP Referer on a per-site basis. I use RefControl to effectively kill all tracking. RefControl effectively allows me to appear to websites as if I just showed up from the root of the website. Websites never see where I came from. Note, I am no longer using this tweak as it has been replaced by the functionality of uMatrix.
RequestPolicy 0.5.28 - Control which cross-site requests are allowed. Improve the privacy of your browsing. Secure yourself from Cross-Site Request Forgery (CSRF) and other attacks. RequestPolicy lets me control what gets loaded from what site on the site I am currently visiting. Effectively, I can use it as a image-free browsing tool should I not whitelist the site I am on. That allows for quick loading of content only. Note, I am no longer using this tweak as it has been replaced by the functionality of uMatrix.
User Agent Switcher 0.7.3 - Adds a menu and a toolbar button to switch the user agent of a browser. Lets me change the UA of T4Fx. I can appear as an iPhone, an iPad, a Windows box or an Intel Mac to any website. Great for killing those annoying popups that tell you that your browser is outdated. It also can let you see mobile content if you are an a particularly intense site. As mobile content is generally faster loading, you get a faster experience. That's the concept behind Classilla.
One notable extension I do NOT use and that is Ghostery. Ghostery has a serious memory leak and while it's great at what it does, I've now found other ways to eliminate tracking that does not require it.
Part II: Config:
browser.cache.compression_level, 1 - This setting determines whether Firefox compresses the data in the disk cache, reducing the size of it. The default value is 0, which means compression is disabled. A value of 1 to 9 enables compression, with the higher the value, the greater the data is compressed, but the potentially slower browsing may become.
browser.cache.disk.capacity, 358400 - When a page is loaded, it is cached so it doesn't need to be downloaded to be redisplayed. For e-mail and news, messages and attachments are cached as well. This preference controls the maximum amount of hard drive space to use for caching purposes.
browser.cache.disk.max_entry_size, 16384 - Maximum size of each cached file entry.
NOTE -> THE FOLLOWING DISABLES MEMORY CACHING. If you disable caching from memory and leave caching only on disk this may have an adverse affect as reading from disk is always slower than reading from ram. However, note that if you have memory issues this may help.
browser.cache.memory.capacity, 0 - When images are loaded, they can be cached so they don't need to be decoded or uncompressed to be redisplayed. For e-mail and newsgroups (i.e., Thunderbird and SeaMonkey), messages for IMAP accounts are cached as well in either disk or memory cache, unless synchronized locally already. This reduces the amount of network activity to reload previously viewed messages. This preference controls the maximum amount of memory to use for caching decoded images, messages, and chrome items (application user interface elements). My memory cache is disabled. I don't want T4Fx taking any ram for cache, that's what the hard drive is for.
browser.cache.memory.max_entry_size, 0 - Maximum size of each memory cached entry. Mine is zero, again, because I don't want any caching in ram.
browser.cache.offline.capacity, 0 - Offline caching. Zero, I don't want anything cached offline.
browser.download.animateNotifications, false - This allows disabling the animated notifications shown by the Downloads Indicator when a download starts or completes. Probably not strictly necessary, but killing any animations can potentially reduce CPU/ram use.
browser.fullscreen.animateUp, 0 - In Firefox’s fullscreen mode, toolbars and the tab strip are hidden at the top of the screen and only shown on mouseover. To draw attention to this, they are shown sliding upwards and off-screen when fullscreen mode is toggled on. This preference determines the behavior of that animation. Again, probably not strictly necessary, but can potentially decrease CPU/ram use.
browser.history_expire_days_min, 1 - Mozilla limits the number of entries in its browsing history. This helps performance by reducing the amount of information that must be kept in memory while the browser is running. To prevent culling old history entries prematurely, this preference allows users to set the minimum number of days of history to keep. I keep my history limited. I use bookmarks and speeddial and if I need to get back somewhere I'll bookmark it. Keeping history can reduce performance.
browser.pagethumbnails.capturing_disabled, true - Mozilla has introduced the New Tab Page feature in Firefox 13, which shows thumbnails of the most visited sites from user’s browser history. I don't need T4Fx creating thumbnails as I don't use this and I'd rather have the CPU/ram if possible.
browser.panorama.animate_zoom, false - Disables zoom animation in firefox when switching tab groups. Again, animations…
browser.preferences.animateFadeIn, false - Disable fade in animation of tab titles. Animations…
browser.sessionhistory.max_entries, 2 - Determines the maximum number of pages in the browser's session history. I.e., how many pages I've browsed since I loaded the browser. I keep two entries total to reduce memory usage. It means I can only go back one page but I rarely need to go back more than that.
browser.sessionhistory.max_total_viewers, 0 - Pages that were recently visited are stored in memory in such a way that they don't have to be re-parsed. This improves performance when pressing Back and Forward. This preference limits the maximum number of pages stored in memory.
browser.sessionstore.max_tabs_undo, 0 - Firefox 2.0 introduces a built-in Session Restore feature, allowing the user to continue browsing from where they left off if browser restarts. Since this feature lends itself well to keeping track of data about tabs and windows, it’s also used for re-opening recently closed tabs. This preference controls how many closed tabs are kept track of via the Session Restore service. I am not using Session Restore.
browser.tabs.animate, false - Disable animation for new tab. Animations…
browser.turbo.enabled, true - Unsure as to what this does, but it seems to be deprecated.
config.trim_on_minimize, true - On Windows operating systems, when a program is minimized and left for a period of time, Windows will swap memory the program is using from RAM onto the hard disk in anticipation that other programs might need RAM. Because of the way Mozilla applications are stored in memory, Windows is much more aggressive in swapping out the memory they use, which can cause a delay when the program is restored. This preference determines whether to mark memory as preferably swappable, from a minimized Mozilla Windows application. A Windows setting, but who knows. I set it to true anyway.
content.interrupt.parsing, false - This preference controls whether the application will interrupt parsing a page to respond to UI events. I want the browser to hurry up and display the page. I can wait for UI input to be parsed later.
content.max.tokenizing.time, 150000 - Rather than wait until a page has completely downloaded to display it to the user, Mozilla applications will periodically render what has been received to that point. This preference controls the maximum amount of time the application will be unresponsive while rendering pages. Again, I want the page to display as quickly as possible. Has to be TRIPLE the amount of content.notify.interval.
content.maxtextrun, 8191 - Rather than wait until a page has completely downloaded to display it to the user, Mozilla applications will periodically render what has been received to that point. Because the application must wait for a node to be completed before rendering it, very long text nodes can prevent the page from reflowing. To prevent the wait, Mozilla applications split text nodes to a length specified by this preference. This preference does not exist by default and any value higher than 8192 can cause serious slowdowns on text heavy pages. Yet another "hurry up and display the page" preference.
content.notify.backoffcount, 1 - Controls how many times the page can be rendered while the page is loading. It renders what is available of the page at periodic intervals. If this setting is disabled (set to 0) then the page will not render until it has fully loaded; this will then consequently slow down the time it takes for the page to start to appear. If set to -1, then there is no limit on the number of times it reflows the page; this is the default setting. You can set this to any positive integer, and it will only reflow the page that many times. Reflowing slows down the overall page load time, however it speeds up the display of information. 5 is the recommended setting here.
content.notify.interval, 50000 - This preference specfies the minimum amount of time to wait between page reflows.
content.notify.ontimer, true - This preference specfies whether that timer is active. I.e, it's the switch to turn on the entire page reflow process. If this is not on then all the content.notify settings are irrelevant.
memory.free_dirty_pages, true - When freeing memory jemalloc keeps a bunch of empty pages around in order to speed up future allocations. Having been used these pages are dirty and thus will show up as part of the resident set of a process even if in practice they are not being used. Set to true frees up the dirty pages jemalloc keeps around.
Here we get into the heart of the matter. If you change nothing else, these settings alone will speed things up if set correctly.
network.dns.disableIPv6, true - Disable IPv6 DNS lookups. Disabling this (true) prevents the browser from searching for IPv6 DNS addresses, which speeds up your internet connection.
network.dns.disablePrefetch, false - Prefetching of DNS (IP addresses, links, etc…)
EDIT 12/12/2017: Use the following values here (includes one extra value)
Updated from Post #223.
network.http.keep-alive, true - HTTP is the application-layer protocol that most web pages are transferred with. HTTP keep-alive connections can be re-used for multiple requests, as opposed to non-keep-alive connections, which are limited to one request. Using keep-alive connections improves performance. If a proxy server is not configured, this preference controls whether to use keep alive connections on supporting servers.
network.http.keep-alive.timeout, 30 - This preference determines how long keep-alive connections are kept alive. Default is 115 seconds.
network.http.max-persistent-connections-per-proxy, 100 - See above, this setting is the same but for proxys. Proxy servers max out at 256 so 256 is the upper limit here.
network.http.pipelining, true - Pipelining reduces network load and can reduce page loading times over high-latency connections, but not all servers support it. Some servers may even behave incorrectly if they receive pipelined requests. If a proxy server is not configured, this preference controls whether to attempt to use pipelining. If you do NOTHING else in this guide, TURN THIS ON! Except if you're on dialup that is.
network.http.pipelining.aggressive, true - Firefox offers a “brute force” setting that makes it use pipelining aggressively (network.http.pipelining.aggressive). This setting throws caution to the wind, pipes as much as it can, and uses fallback mechanisms if a problem occurs (e.g. the server closed the connection in the middle).
network.http.pipelining.ssl, true - Emable pipelining on HTTPS.
network.http.proxy.pipelining, true - Enable pipelining when using a proxy.
network.http.request.max-start-delay, 5 - HTTP keep-alive connections can be re-used for multiple requests, as opposed to non-keep-alive connections, which are limited to one request. The preferences network.http.max-persistent-connections-per-server and network.http.max-persistent-connections-per-proxy define the maximum number of keep-alive connections that can be open at one time. This can cause a problem - if the keep-alive connections made are long-lived connections (large downloads), then short-lived connections won't be allowed to connect because the maximum number has already been reached. The solution is to allow the maximum number of keep-alive connections to be exceeded after a certain period of time. This preference controls that amount of time. Default is 10.
network.prefetch-next, false -
network.protocol-handler.external.disk, true - Link prefetching is when a webpage hints to the browser that certain pages are likely to be visited, so the browser downloads them immediately so they can be displayed immediately when the user requests it. This preference controls whether link prefetching is enabled. I have it disabled so the browser is not spending time prefetching links I probably won't click on.
network.websocket.max-connections, 400 - WebSockets is an advanced technology that makes it possible to open an interactive communication session between the user's browser and a server. With this API, you can send messages to a server and receive event-driven responses without having to poll the server for a reply. Note that in a secure environment, such as TOR you would want only 1 connection. Default is 200.
nglayout.initialpaint.delay, 0 - Mozilla applications render web pages incrementally - they display what's been received of a page before the entire page has been downloaded. Since the start of a web page normally doesn't have much useful information to display, Mozilla applications will wait a short interval before first rendering a page. This preference controls that interval. Default is 250 milliseconds. I do not want any delay so my setting is zero.