Safari is by far the most popular web browser for Mac. Mostly, that’s because it’s pre-installed with macOS and made by Apple. At the same time, Safari is also fast, has some great features, and is deeply integrated with other Apple apps and services, like share sheets and Shortcuts. Most of the time, Safari works brilliantly. But now and again, it can do some strange things. One of those is when Safari keeps downloading unknown files. Has that ever happened to you? If so, keep reading. We’ll explain why and what you should do to fix it.
Why does Safari keep downloading unknown files?
There are two main reasons why Safari may keep downloading unknown files. The first is that you have navigated to a website that distributes malware. The second is that there is a bug in Safari or in the way the website is coded that causes a file to be downloaded every time Safari reloads a web page on a specific website.
Are the unknown files harmful?
They could be. If they contain malware, it’s possible that they could cause problems for your Mac. macOS has some excellent security in place to stop your Mac from being accessed without your permission and infected by malware. But much of it relies on you being vigilant and reading warnings that appear on the screen before responding to them. It’s important that you read the warnings carefully and respond appropriately. For example, if you see a request in Safari to allow downloads from a website, don’t just click it without making sure that you’re happy to accept downloads from that site.
What to do if Safari keeps downloading unknown files
If you’re sure the files are being downloaded by Safari — that is, that you see the download progress in Safari and the files don’t just appear in your Downloads folder — the first thing to do is to close all the open tabs. It’s likely that the downloads are coming from one of those.
The next step is to clear out all the data that websites you have visited have placed on your Mac. Here’s how to do that:
- Click on the Safari menu and choose Settings.
- Choose the Privacy tab.
- Click Manage Website Data.
- Wait for the data to load, then click Remove All.
When you do that, all the temporary and cache files that sites have downloaded onto your Mac, including cookies, will be deleted. That may mean websites are slower initially, but it may fix the problem.
Disable extensions
Extensions in Safari add functionality to the browser. However, if you have installed extensions that are now out of date, they could be misbehaving and causing it to download files.
- Go to Safari > Settings.
- Choose the Extensions tab.
- Deselect the box next to the extensions you want to disable.
- If you want to uninstall an extension completely, select it and click Uninstall.
If the files stop downloading when you disable extensions, you know one of the extensions was the culprit. You can then enable them again one by one until you discover which one is at fault.
Update macOS
It’s a long shot, but the problem might be caused by a bug in Safari that is fixed in the latest version. In any case, it’s always a good idea to update macOS. Go to Apple menu > Settings > General > Software Update to check if an update is available. If there is one, follow the on-screen instructions to install it.
Reinstall macOS
If nothing else works and Safari keeps downloading unknown files, the only course of action left is to reinstall Safari. However, Safari is part of macOS, so the only way to reinstall it is to reinstall macOS.
Before you do that, you should back up all your data. If you back up to Time Machine, you can restore your data and your settings from the Time Machine backup during the installation process.
Now, boot into recovery mode:
- For an Intel-based Mac, restart while holding down Command+R. Release when you hear the startup chime.
- For a Mac with Apple silicon, restart while holding down the power button. Release when you see the Startup Options Window. Select Options > Continue.
Once booted into recovery mode, select Reinstall macOS from macOS Utilities and follow the on-screen instructions.
Safari is a great web browser, and most of the time, it works very well. But occasionally, it misbehaves, and sometimes it may download unknown files without you choosing to download them. That could be because of a file that it has previously downloaded — which could be malware — or it could be a bug. If it happens to you, follow the steps above to fix the problem and stop it from happening again.