• On GameSpot: So-called 'Halo killer' gets 23 to life
advertisement
September 16, 2009 12:55 PM PDT

Slow Browsing with Safari? Recent odd behavior?

by Topher Kessler
  • Font size
  • Print
  • 33 comments
Share

Apple's Safari web browser is one of the fastest available, with advanced Javascript handling and fast HTML rendering, which along with it's simple and straightforward interface makes it quite appealing. Sometimes, however, people are finding the browser (and web browsing in general) to be quite slow on their Macs.

There are a variety of reasons why web browsing can be slow and as such, if this happens you can do several things to help combat it:

1. Try OpenDNS servers

The DNS servers for your connection are provided by your ISP, and their performance may vary depending on how the servers are configured, how much traffic they are getting, and what other processes are running on the same systems. Adding OpenDNS servers (208.67.222.222, and 208.67.220.220) to your system should speed up the process by which domain names are translated into IP addresses, and allow your system to load pages and web resources without delays.

Custom DNS Servers entered in the AirPort configuration

(Credit: Screenshot by Topher)

2. Reset Safari

Many times corrupt application resources are the reason for an application's slow performance. Safari has a variety of these, and Apple has conveniently enabled quick resetting of these resources through the "Reset Safari..." option in the "Safari" menu. Despite this, some people may wish to still reset Safari's resources manually. To do this, locate and remove the files in the following folders:

/username/Library/Cookies/
/username/Library/Caches/com.apple.Safari/
/username/Library/Caches/Metadata/Safari/

Then remove the following from the /username/Library/Safari/ folder:

Downloads.plist
Form Values
History.plist
HistoryIndex.sk
LastSession.plist
LocalStorage (folder)
TopSites.plist
WebpageIcons.db

3. Delete caches

Safari enables you to remove its cache from the "Reset Safari" option; however, you can use a third-party cache cleaning utility built for your operating system to remove all system caches to clear any faults with them that might be affecting Safari. Several of these utilities are: OnyX (currently 10.5 only), Leopard/Snow Leopard Cache Cleaner, and MainMenu.

4. Remove plugins.

If a plugin is not functioning properly it may cause Safari to run slowly, especially when loading PDFs, images, movies, and other media files. Try removing all third-party plugins from the /Macintosh HD/Library/Internet Plugins/ folder, and /username/Library/Internet Plugins/ folder. After this, relaunch Safari to see if the problems persist. Then install the latest version of the plugins you use.

On a slightly different note, I've found when browsing Apple's support sites and discussion forums that Safari will sometimes not communicate properly with the Apache web server that is hosting the support sites. When this happens I get one of these two errors:

Top: Request Entity Too Large error in Safari when trying to read knowledgebase articles. Bottom: Bad Request error in Safari when browsing the Apple discussion boards

(Credit: Screenshot by Topher)

This problem seems to be with how Safari is handling cookies for the website, and deleting cookies reduces the prevalence of these errors; however, they begin to occur again after a while. Sometimes the only way to clear the problem is to quit and relaunch Safari. This appears to be a problem that is specific to Safari, since it does not happen in other browsers, and hopefully will be addressed by Apple soon. However, in the mean time if a fix or workaround surfaces, I will post it here.

Topher has been an avid Mac user for the past 15 years, and has been a contributing author to MacFixIt since Spring 2008. One of his passions is troubleshooting Mac problems and making the best use of Macs and Apple hardware at home and in the workplace.
Recent posts from MacFixIt
Snow Leopard: Sound volume resets after rebooting Mac
System Preferences not opening properly
Managing the user spelling dictionary
Apple updates Airport, MacBook, and Superdrive Firmware.
Google Chrome Beta for OS X now available!
Move your Time Machine backup and continue using it to backup
iWork & iWeb unexpectedly quit after upgrading to Mac OS X 10.6.2
Apple KB Updates: iWeb and iWork unexpected quits, Voiceover slowness, and iTunes unable to activate iPhones.
Add a Comment (Log in or register) (33 Comments)
  • prev
  • 1
  • next
by FixMaX September 16, 2009 1:23 PM PDT
In my case Safari 4.0.3 and previous versions is fast, except the very first site that I visit when I open Safari. If any page loads on one second or so, the very first page after openening Safari takes 5 times more to load. What can it be? On Mac OS X 10.5.8 and previous versions. Thanks.
Reply to this comment
by tkessler September 16, 2009 3:44 PM PDT
What kind of internet connection are you using? As far as Safari goes you could try the various program resets, but it sounds like the initial connection is taking a while to either authenticate or otherwise establish a connection. This could be a problem with your DNS servers, if the first one used does not work then the system will try the next one. Try entering new DNS servers in your network preferences (the OpenDNS servers in the article should work).
by FixMaX September 16, 2009 4:39 PM PDT
I am answering here because the "Reply to this comment" does not show on the message by tkessler. Thanks for the reply. These are the answers to your questions:

- I have ADSL2 with NAT Ethernet router.
- I have changed the DNS at Sytem Preferences - Network - Built-in Ethernet - DNS Server - Apply, yet the issue remains.

Thanks again.
by rhpatrick September 17, 2009 4:50 PM PDT
I believe I stated the same thing in my comments; it appears that Safari was written with the inability to delete the "browser cache" upon closing it. There are cache files in the user library, but that's not the file; it appears that thee is a "browser cache folder" which takes 15 to 30 Megs maybe more; it depends on the sites you visit. As I stated Opera and Omnieb provide the deletion of this file under their preferences. Just make sure you check or configure the browser to do this.iCab also has this option.
by FixMaX September 17, 2009 11:42 PM PDT
TO THE ADMINS: the "Reply to this comment" is utterly confusing because if you are the owner of an original comment and want to reply to other user's comments to such original one, there is no option to do it other than to reply to your original comment. THAT IS CONFUSING.

To rhpatrick:

I guess you mean iTweaX at <http://www.itweax.net>. I have tried iTweaX 2.0.2 (Cleaning/Internet/Browser/Apply) on Safari 4.0.2 on Mac OS X 10.5.8 to no avail. Actually, the first page takes even longer to load now. As said on my original post, my problem is that Safari takes about five times more to open the very first page once I open it, no matter which page. The subsequent pages load five times faster. Until I quit Safari and open it again, in which case the very same issue arises.
by REShaman September 16, 2009 4:27 PM PDT
Thank you Topher for the information about adding DNS addresses. As one who has been puzzled by the clunky performance I have actually been experiencing rather than the speedier 4.0 Safari iterations which for me lags when attempting to browse to certain addresses, the addition of the DNS addresses was useful. Whether the culprit is my ISP or Safari, I appreciate the increased speed now present while browsing.
Best,
Richard
Reply to this comment
by macsense September 16, 2009 9:02 PM PDT
Those DNS entries are shown being made on the Mac. Wouldn't you make those in your router if you had one rather than Network preferences?
Reply to this comment
by KroSha September 17, 2009 2:07 AM PDT
Yes, you should. I was having lots of trouble with slow surfing and email server timeouts. Although OSX will prefer user specified entries to ISP supplied ones, changing the DNS settings in Network Prefs did nothing, as the default setting on my router hijacks all DNS requests to the ISP servers. Look in your router documentation and add the OpenDNS servers to your router to be sure that your requests are being sent to OpenDNS.
by tkessler September 17, 2009 8:39 AM PDT
Manually entered DNS servers should take precedence over those provided automatically by the ISP/Router. Entering them in your router should only be beneficial by allowing all users to automatically use them.
by KroSha September 18, 2009 2:01 AM PDT
"Manually entered DNS servers should take precedence over those provided automatically by the ISP/Router."
I already said that.
"Entering them in your router should only be beneficial by allowing all users to automatically use them."
And it makes sure that the router is using them as well. SOME routers intercept DNS requests and send them to the router specified servers. The user defined ones SHOULD take preference, but that doesn't always apply, as there is another layer of software between the Mac and the interweb. It SHOULD be transparent, but it isn't always so.
by ehoughton--2008 September 16, 2009 9:35 PM PDT
If you are adding the open DNS servers, should you remove the ISP specific one? If not, does it make a difference what order they're in?
Reply to this comment
by tkessler September 17, 2009 8:41 AM PDT
The first ones on the list are the first used, and the manually entered ones should be used before the ones provided by your ISP. There are ways to remove the automatically provided ones, but it takes editing the network configuration files manually.
by orgrsl September 16, 2009 10:06 PM PDT
Thanks for the tip re OpenDNS servers, Topher. I've been noticing that my Safari 4.0.3 has been behaving erratically since I upgraded to Snow Leopard--most of the time it's OK, but recently it's starting to take forever to load a page. Never used to behave like that. I've changed the DNS servers to the ones you listed (putting my ISP-specific one at the bottom). So far, so good.
Reply to this comment
by Evan6330 September 17, 2009 8:41 AM PDT
How you were able to put the ISP specific DNS at the bottom? Mine remain at the top, impossible to move it, it's grayed.
by tkessler September 17, 2009 9:51 AM PDT
@Evan6330, your manually entered servers should take precedence over the grey one, even though it is at the top of the list.
by orgrsl September 17, 2009 12:09 PM PDT
Evan6330, when I clicked the "+" to add the new DNS servers, it showed that the grayed-out ISP-specific one was actually going to be *overwritten* by whatever I entered. Luckily, I made a mental note if it before I added the new ones, and simply re-added it to the bottom of the list.
by tkessler September 17, 2009 12:20 PM PDT
@orgrsl, the default one will still be there, and if the manually entered DNS servers do not respond the default one will take over. Adding it back will not hurt anything, but should not make a difference either way.
by milk313 September 20, 2009 8:11 AM PDT
How Can we fix this, I am having the same problem and I can not continue to use safari if it doesnt auto assume the .com There is no ctrl+enter with safari. Its driving me nuts
by WhiteDog September 17, 2009 1:39 AM PDT
I have another problem with Safari 4.0.3 in Snow Leopard. When I zoom in on a page in order to read it more easily, radio buttons disappear. The page zooming function was even more problematic in OS X 10.5.8. Likewise, in Leopard the little expansion corner at the lower right of text boxes disappeared. It seems to be working in Snow Leopard - though I'm holding my breath it doesn't vanish again.
Reply to this comment
by Dave K September 17, 2009 10:49 AM PDT
Nice suggestion! The OpenDNS servers do indeed seem much snappier than the default ones from my ISP (ATT DSL). They do appear though to lack one feature that I liked. My default ISP DNS servers always assumed a ".com" domain if one was not specified. For example, in the address field of Sarari, I could type simply "Macfixit" or "CNN" or whatever and it would automatically assume the .com part. (Naturally if the domain was .org or .gov or .net or something, I had to type that.) The OpenDNS servers do not appear to make any assumption, so if you enter an address without the full domain, it takes you instead to an OpenDNS search page.
Reply to this comment
by September 17, 2009 12:32 PM PDT
I also noticed a slowdown in SL and Safari. I have a small local network, and had added the OpenDNS servers to my Time Capsule Airport, but was still experiencing Safari SL slowdowns. I tried adding the OpenDNS servers directly to the 'slow' mac in the System Pref/Network/Advanced/DNS window and..yeehaw. Speed back to normal (fast!).

:-)
Reply to this comment
by rhpatrick September 17, 2009 12:39 PM PDT
The safari slowdown results from a "huge increase" in the browser cache file" I use i Tweax to delete this cache file. Other browsers such s Opera,or Omniweb give you the option to "remove" this file when you close the browser. The size has ranged from 15 to over 30 Megs of cache. While the browser stores this, it becomes a hardship for the user especially when thee is no real way to delete the cache. Deleting the "empty the cache file will not fully resolve this slowdown; deletion of the browser cache will. Whee is is file?
Robert
Reply to this comment
by Kerry Dawson September 18, 2009 7:12 AM PDT
Can you tell me if the Safari empty cache file accomplishes what you're mentioning. I do have Snow Leopard cache cleaner. I used to use Onyx but it isn't SL compatible but once when I used it to delete cache files it mucked up sync services some how so I'm always leary about using these as they have far reaching effects.
by JaLansing September 17, 2009 7:38 PM PDT
Thank you so much for the OpenDNS server tip. Safari is loading web sites much faster. Simple tip with great results!
Reply to this comment
by macdad614 September 18, 2009 5:01 AM PDT
In printing a pdf file for future reference, the comments are missing. Anyone know how to remedy this without copying the entire page and pasting on a word processor?
Reply to this comment
by tkessler September 18, 2009 9:17 AM PDT
That is odd. I will let folks know about it and hopefully something can be done. It might be an easy fix, but for now click the "1" at the top of the comments and they will load in a new window, from which you can print them separately. Then use preview to combine them with the article. I might post a small article about this so people can use it as a workaround if they print articles.
by Kerry Dawson September 18, 2009 7:06 AM PDT
This was an interesting article as with V4 and on of Safari I thought it to be a bit sluggish. I noticed a poster mentioned the opening page takes forever which I too noticed. I also noticed that there just seemed to be a lot of delays when jumping from page to page. Finally, sometimes when I'd hit the back key to go back a page it could seem slow.

I thought that I'd give Firefox another whirl to compare to see if it was something with my network.I hadn't used Firefox in a while and immediately noticed i liked the interface better. However, it seemed faster. In the past, it was always noticeably slower than Firefox and on top of that I never liked the interface much nor the way it rendered pages. That's all gone.

So I did all those tweaks to Safari and honestly I don't see a difference. There was a tweak I read somewhere that was supposed to speed up Firefox but again I didn't notice a difference. Yet, I do seem to feel Firefox is faster.

I've gotten to use both now. When I started to use Firefox I ran across two extension apps I love. One is iMacro and even though I have Quickeys, use it constantly and couldn't live without it, iMacro is a touch faster as I guess its working right in Firefox. The other extension I find super handy is Read-it-Later.

I've started to use both Firefox and Safari. Firefox is actually recommended for two sites I visit regularly one being my online investment service. I am tending to go Safari when I think I want to use services which I do use frequently to mainly grab stuff to SOHO notes. The other thing I like Safari for is quick forms filling of my info out of Addressbook. However, when I'm in Safari I might go to Facebook and if I write an e-mail it always crashes Safari at the second paragraph, an odd bug which I've reported to Apple.
Reply to this comment
by September 18, 2009 3:29 PM PDT
Okay-- I'm impressed. I was getting pretty frustrated with the Safari slowness issue because when I first went to Safari 4 it was fast! I changed the DNS servers and what a difference! (It took me awhile to figure out what was meant by changing it in the router instead of the Network settings; I first added them in the Network settings and there was no difference. Also when I went to the Airport Utility I found out I had missed a firmware update.) My question is do I also need to erase or change the domain name also?
Reply to this comment
by hht311 September 19, 2009 5:46 AM PDT
This is all well & good BUT !
Why doesn't Safari load PDF pages ?
Reply to this comment
by tkessler September 20, 2009 8:47 AM PDT
Do you have Adobe Reader installed?
by macewan_ September 19, 2009 10:11 AM PDT
Hyphen between Plug & Ins with "I" not "i".

Internet Plug-Ins

http://www.flickr.com/photos/macewan/3933975327/
Reply to this comment
by tkessler September 20, 2009 8:47 AM PDT
Most people should be able to find the folder and remove the relevant files. The word "Plugin" is an alternate usage to "Plug-In", similar to webpage vs Web page.
by NCKitkat September 22, 2009 6:03 AM PDT
I have noticed strange things, probably due to plugins- the most annoying is a slow-down when I go to my grandson's nursery webcam login. It is supposed to be 2 minutes, but it is so slow that it is pixelated, and does not go for 2 minutes. I thought it might also be quicktime, but can't find where to try and update this. also get messages about flash not working.-?
Reply to this comment
(33 Comments)
  • prev
  • 1
  • next

Navigate MacFixIt

  • Help
  • Archives
  • Utilities
  • Forums
advertisement

About MacFixIt

MacFixIt is CNET's troubleshooting resource for all things Mac. The information here helps you navigate the ins-and-outs of Mac ownership with how-tos, troubleshooting information, news, reviews, and more.

Add this feed to your online news reader

MacFixIt topics