Safari: Safari is the default web browser that comes with your Mac OS X designed by Apple based on the Apple’s WebKit engine. It was first released in 2003 with Mac OS X 10.3 – Panther, then a mobile version was included in iOS devices since the introduction of the iPhone in 2007. A Windows version of Safari was also released in the year 2007, which Apple discontinued in 2012. The first version of Safari for Mac was named Safari 1 and now the current version as of writing is Safari 12.0.2, released for macOS 10.14 Mojave. It got some new features like Favicon or website icons in tabs and more. For more information, read What’s new in macOS Mojave. Apple claims that the new version of Safari is more secure and reliable but as we know that nothing is perfect in this world. Just like other browsers, Safari also gets infected with Malware, Spyware or Adware. Sometimes new updates from Apple are rolled out which makes Safari unstable or even remove it from the system. In order to deal with such situations you should know how to reinstall safari.
Here in this article, I would be explaining to you about some major issues with Safari along with their solutions and if none of the solutions works, the last resort to you is reinstall Safari which I have covered in the end.
Issue / Error With Safari
Safari was recently in hot search trends due to Apple’s latest software updates to the Safari web browser issued on 3rd December, 2015 which reportedly failed and removed Safari from users’ systems. There was another update to Safari which made it incompatible with the OS and changed the safari logo to a crossed out circle. If you would try to open Safari it would show an error message that reads “The version of safari installed on this Mac is not compatible with the current version of OS”. You may also get one of the following error messages.
- “This version of Safari is no longer supported. Please upgrade to a supported browser.”
- Safari crashes as soon as you open it and shows error message Safari quits unexpectedly.
- Can’t connect to the server
- Safari loads partial webpage”
- Safari may become corrupt and may not run at all or runs very slow like a snail, it takes ages to open a web-page, while other browsers run perfectly fine. So if it is not working or having problems to browse websites, you may need to reinstall it.
As per the Apple there is no way to reinstall Safari except reinstalling OS X. Reinstalling OS X does not delete any user’s files, however, its a lengthy process and require so much time and care. But before we reinstall the OS X, I would suggest you to try the following troubleshooting which may fix the issue with Safari. We could also install Safari as a standalone app using a third party software called Pacifist, which is explained in the end.
Troubleshooting the issues with Safari
#1. Check to see if Safari is running in 32 bit mode.
Apple introduced 64-bit version of Safari with the release of Snow Leopard (OS X 10.6), but it was still possible to run Safari in 32-bit mode for backward compatibility. At the time of release so many JavaScript application and Safari extensions were not designed for 64 bit version of Safari so users had to run Safari in 32-bit mode. After Mountain Lion( OS X 10.8), Apple removed option to change the bit mode of Safari as all of the extensions and JavaScript Applications were already upgraded to run in 64 bit mode.
Check if Safari is running in 32 bit mode
Right or control click the Safari icon in your Applications folder then click Get Info. If the box next to: Open in 32 bit mode is Checked, Uncheck it, quit then relaunch Safari.
2. Reinstall Flash Player Plug-ins.
Safari has a long term issue with Flash Player which was also published in an article written by Steve Jobs- Thoughts on Flash. Check safari by Uninstalling flash Player. After the safari is uninstalled delete its left over files from the following locations if available.
/Library/Internet Plugins /Library/Application Support/Adobe/Flash Player /Library/Application Support/Adobe/Flash Player Install Manager /Library/Caches/Adobe/Flash Player /Library/Preferences/Macromedia/Flash Player ~/Library/Preferences/com.adobe.flsh-12.plist ~/Library/Preferences/com.adobe.flsh-11.0.plist ~/Library/Preferences/Flash 11.5 MRU ~/Library/Application Support/Adobe/Flash CS5.5/ ~/Library/Application Support/Adobe/Flash
3. Restart your computer.
4. Reinstall and enable Flash player for Safari.
Install Flash Player directly from Adobe. If you are having trouble with web installer, download the standalone Flash Player version for Safari and Firefox – NPAPI directly from
https://fpdownload.macromedia.com/pub/flashplayer/latest/help/install_flash_player_osx.dmg
5. Remove incompatible Flash Extension
Remove ClickToFlash extension if it is installed, it can prevent Flash based videos from streaming. It can be found as a plugin in /Library/Internet-Plug-Ins
.
6. Make sure the JavaScript and plugins are allowed in Security settings of Safari Preferences window.
Also check the Safari Develop Menu to make sure “Disable JavaScript” is not checked. Learn how to enable Develop Menu in Safari.
7. Check Safari after Turning Off the IPv6 Support.
On February 4, 2008, IANA adds AAAA records for the IPv6 addresses of six root name servers. With this transition, it became possible to resolve domain names using only IPv6.
On August 28, 2009, OS X 10.6 Snow Leopard was released to manufacturing worldwide and reported to have issues with safari if using IPv6.
On June 6, 2012, the Internet Society together with many other big companies and organizations held World IPv6 Launch Day, a global permanent deployment of IPv6.
On July 25, 2012, Mountain Lion- OS X 10.8 was released and had a known issue with ipv6 and dns implementation and people started using Chrome and firefox until Apple admitted there was a bug and fixed it. The Same bug chased OS X 10.10 Yosemite too.
To fix this issue, first make sure your Mac is up to date by installing all Software updates. If its already updated and you still have the same issue then turn off the IPv6 as mentioned below.
For OS 10.6.8 and earlier
a.) Go to System Preferences > Network > Advanced > TCP/IP > Configure IPv6: Off. Click “OK” then Apply and then test after restarting the Mac. You could also use the following command in terminal to do the same.
Turning off IPv6 support for ethernet:
networksetup -setv6off Ethernet
Disabling IPv6 for wireless:
networksetup -setv6off Wi-Fi
Note: Disabling IPv6 may also stop you from using some of the core OS X system services, like the discovery service Bonjour, AirDrop, because they use IPv6. Accordingly, disabling IPv6 may render AirDrop sharing unusable, certain print services configured on Bonjour will become unavailable, and some other convenient Mac features may turn inoperable as well.
For OS X 10.7 and above
b.) Go to System Preferences > Network > Advanced > TCP/IP > Configure IPv6: Link-local only. Click “OK” then “Apply” and then close preferences. Check Safari after Logout and log back in, it should be working fine.
Re-Enabling IPv6 for Wi-Fi & Ethernet in OS X
Of course, reversing the above change is also possible, and you can re-enable IPV6 support with the following command strings entered into the terminal:
For Wireless Interface
networksetup -setv6automatic Wi-Fi
For Ethernet Interface
networksetup -setv6automatic Ethernet
8. Flush the DNS Cache
OS X keeps a local cache of resolved DNS queries for a time defined by the DNS server. Sometimes it might be necessary to reset the cache immediately and re-query a DNS server if an entry on your DNS server has recently changed. To Flush (Reset) DNS Cache, use the terminal commands below for the version of OS X you’re using.
OS X Yosemite and later
Use the following Terminal command to reset the DNS cache in OS X v10.10.4 or later:
sudo killall -HUP mDNSResponder
Use the following Terminal command to reset the DNS cache in OS X v10.10 through v10.10.3:
sudo discoveryutil mdnsflushcache
OS X Mavericks, Mountain Lion, and Lion
Use the following Terminal command to reset the DNS cache in OS X v10.9.5 and earlier:
sudo killall -HUP mDNSResponder
Mac OS X Snow Leopard
Use the following Terminal command to reset the DNS cache in OS X v10.6 through v10.6.8:
sudo dscacheutil -flushcache
9. Try Open DNS
For, “can’t connect to server” issues, Apple suggests using Open DNS or Google DNS. If you are using Safari 5.0.1 or later and you are facing issues like Slow or partial webpage loading, or webpage cannot be found. Try open DNS server mentioned below.
Open System Preferences > Network > Advanced > DNS
Click + and type:
208.67.222.222
Click + again and type.
208.67.220.220
Click ‘OK’.
Quit and relaunch Safari to test.
If that didn’t help, go back to the DNS tab. Select the 208 addresses then click ➖ under the DNS Servers panel to delete.
Then click + to add Googles’ DNS Server.
8.8.8.8
8.8.4.4
Then click OK and try Safari.
10. Scan the Computer with Malwarebyte Anti-malware
Your Safari might be infected with Malware, Spyware or adware which is causing Safari to crash. I have created a list of Common Malware and Adware, check to see if your Computer is infected with any of these.Scan your computer with Malwarebyte -Anti-malware for Mac. Remove all the found items as they are harmful to your computer.
Look into the following folders and browse their contents for any third-party add-on files. Move the third party add-on files to trash.
/Library/Internet Plug-Ins/ /Library/Input Methods/ /Library/InputManagers/ /Library/ScriptingAdditions ~/Library/Internet Plug-Ins/ ~/Library/Input Methods/ ~/Library/InputManagers/ ~/Library/ScriptingAdditions
11. Reset Safari
If all the above methods have been tried and Safari still does not work. Reset the Safari by deleting the following files.
~/Library/Logs/ ~/Library/Caches ~/Library/Cookies/Cookies.binarycookies ~/Library/Safari ~/Desktop/Safari ~/Library/Preferences/Apple/Safari ~/Library/Preferences/com.apple.Safari.LSSharedFileList.plist ~/Library/Preferences/com.apple.Safari.RSS.plist ~/Library/Preferences/com.apple.Safari.plist ~/Library/Preferences/com.apple.WebFoundation.plist ~/Library/Preferences/com.apple.WebKit.PluginHost.plist ~/Library/Preferences/com.apple.WebKit.PluginProcess.plist ~/Library/PubSub/Database ~/Library/Saved Application State/com.apple.Safari.savedState ~/Library/Preferences/com.apple.internetconfigpriv.plist ~/Library/Application Support/CrashReporter/
Delete Keychain entry named “Safari Extensions list” from Keychain Access located in /Application/Utilities folder.
Clear the NVRAM variables by typing the following command at terminal.
sudo nvram -c
Why will you have to Reinstall Safari?
If all the above mentioned steps have been exhausted and safari still doesn’t seem to be working then it might be a possibility that “Safari.app” application file has become corrupted. And the final resort to you is either clean reinstall Safari or Reinstall the OS X.
How would you Uninstall Safari?
Uninstalling Safari from Mac is not as easy as uninstalling any third party apps. To uninstall safari you must either reinstall the operating system or use a third party app to uninstall the application for you and again to reinstall Safari, you either reinstall the whole Operating system or use a third party software to extract it from OS X installation file.If you normally try to move safari to trash you will see following error message.
“Safari can’t be modified or deleted because it’s required by OS X.”
Follow the below mentioned steps to uninstall Safari.
1. Uninstall Safari using Terminal Command
Launch the Terminal, located in /Applications/Utilities/ folder. Type the following command and hit enter to change the current working directory(CWD) to the Applications directory.
cd /Applications/
Now that you are in the Applications folder, you can start deleting apps. You will not get a confirmation of the removal, the app will simply be uninstalled completely. The following commands will only work when used in the /Applications/ directory.
sudo rm -rf Safari.app/
2. Uninstall Safari manually.
Go to the /Applications folder and Right-Click or Control-click on Safari icon and select Show Package Contents.
This will open a new folder called contents and it will have other bundled software and info.plist files inside it. Simply select all the package contents and delete them to uninstall safari.
After deleting the package contents you also need to delete other supporting configuration and preferences file for Safari exactly as mentioned above in Step 11-Reset Safari. Restart the computer now and Safari is uninstalled completely.
3. Uninstall Safari using a Third party App.
CleanMyMac 3 is a free application that can be used to uninstall Safari on macOS. In OS X El Captian, you cannot remove Safari with CleanMyMac 3 and will run into this message: “Safari.app” couldn’t be removed because you don’t have permission to access it.”
Reinstall Safari on my Mac
How would you Reinstall Safari?
There are multiple ways of reinstalling Safari. If your OS X version has got a new Combo update released and you haven’t installed it, Look into the details of Combo update and see if it contains Safari. If it has Safari then installing the Combo will bring Safari back as a fresh new updated version. If your OS X is already updated then follow one of the steps below.
#1. Safari can also be downloaded from Softpedia and reinstalled –http://mac.softpedia.com/get/Internet-Utilities/Safari.shtml
Download it from the Softpedia and reinstall it as usual.
#2. Use Pacifist to extract Safari out of the original OS X installation file.
Pacifist is a shareware application that can extract the contents from Mac OS X .pkg package files, .dmg disk images, and .zip, .tar, .tar.gz, .tar.bz2, and .xar archives. This is specially used when a native OS X application becomes damaged and needs to be reinstalled without the hassle of reinstalling all of Mac OS X.
Pacifist is compatible with Mac OS X 10.8 or higher, including Mac OS X 10.11 “El Capitan”. Pacifist requires a 64-bit Intel™ processor.
Download the latest version of Pacifist in zip or disk image format. For users using versions of Mac OS X older than 10.8, download older versions of Pacifist here. Now to Reinstall Safari you need the source image to extract safari from.
You can extract Safari from the following sources.
- Original OS X installer dmg file.
- Hidden Recovery Partition on any Mac.
A.) Extract Safari from original OS X installer DMG file.
90% of the times your Mac keeps a copy of the complete OS X installer that you downloaded to upgrade your system. This download is by default saved in /Application folder. Go to the /Application folder and see if you have OS X El Capitan or the current running version of OS X on your Mac, usually named as “Install macOS Sierra.app“. if you do not see it in Application folder, download it from the App store.
1. Open Pacifist and select the first option “Open Package”.
2. Choose the original OS X installer.dmg or macOS Installer.app file from /Application folder.
3. Then browse through the contents and expand the Application folder inside the extracted .dmg or .app file to go to the Safari or you can simply type safari in the search box on the top right corner of the windows.
4. Right-Click or Control-Click the Safari.app and select install. It will install Safari to its default location /Application/Safari.app.
B.) Extract Safari from Hidden Recovery Partition on your Mac.
Recovery Partition is a small (650MB) hidden partition on your Mac’s internal hard drive which is reserved for common utilities such as Time Machine, Terminal, Disk Utility and other built in set of utilities as part of the Recovery System. It even has Safari. We can extract Safari from this partition using Pacifist, if the partition is accessible. There might be a possibility that your Mac does not have a recovery partition or the recovery partition is corrupt. You can check if your Mac has a recovery partition.
To access the Recovery Partition, you will have to first turn on the debug menu in “Disk Utility” as mentioned below:
defaults write com.apple.DiskUtility DUDebugMenuEnabled 1
3. This command enables the hidden Debug menu to appear in Disk Utility. Open Disk Utility and look for “Debug” alongside ‘Help’.
4. Click on the new Debug menu and select “Show every partition“.
5. Now you should see the ‘Recovery HD’ in the left-hand pane of the Disk Utility window although it will be grayed out.
6. Select ‘Recovery HD’ and click the Mount icon, at the top of the Disk Utility Window, to make it active. After it is mounted, It will show up on desktop as a drive icon.
7. Now use Pacifist to extract Safari.app from Recovery Partition as mentioned below.
- Open Pacifist and click Open Package then select recovery HD.
- Go to the folder named “com.apple.recovery.boot” and select BaseSystem.dmg and click open.
- Once the BaseSystem.dmg is loaded you would see all of its contents. Select safari under Applications folder and then click on “Extract To” on the top and install it in /Application Folder.
- If it asks you to merge or Replace, Click Replace and Safari would be installed in the default Applications folder.
#3. Reinstall OS X to Reinstall Safari.
If all the above steps have been tried out and it still does not fix the Safari issue. The last resort to you is Reinstall OS X to reinstall Safari, it will install a fresh copy of both your operating system and Safari and will not loose any of your files or document they will remain as is. Follow the step mentioned below for Reinstalling OS X.
Restart your computer and hold down “Cmd+R ” together until you see gray Apple Logo. Make sure you’re connected to the Internet, select “Reinstall OS X” and click “Continue.” Follow the onscreen instructions to install OS X.
Hope you found it helpful and it helped you reinstall Safari on your Mac. In case you still have the same issue and it does not fix the Safari problem, then write to us in the comment section below.
Comment was meant for this article.
I am so relieved to have found this blog entry. I was about to go on a mission to beat up some Apple "Geniuses" until i got a positive result here. Thank you Nasir.