Overwriting a much-needed file is every computer user's worst nightmare. Even when your Mac warns you that the file with this name already exists, you don’t stop and think it through — you just hit Replace and now the old file is gone. This happens way too often to busy people.
So what do you do now? Is it possible to rescue an overwritten file? Well, you’ll be pleased to know that all hope is not lost. The overwritten file can be recovered. On Mac, the file still exists somewhere on your system, and, with the help of a few tools, you can get it back.
These tools are Time Machine, Get Backup Pro, and Disk Drill.
What is an overwritten file?
Before we give you practical solutions, let’s quickly outline what an overwritten file is, how you can overwrite a file, and how does it affect you.
Essentially, an overwritten file is a file replaced with another file — whether accidentally or intentionally. Have you ever seen an error that reads something like “this file already exists, want to replace it?” That’s the one. Usually, you get an error like that if you want to save a file with the name identical to the name of another file on your Mac. If you choose Replace, the original file will be overwritten.
But here’s an important thing to note: overwriting a file on Mac doesn’t mean you immediately delete the data it references. When you hit that Replace button, you basically delete the name of the file, thumbnails, and the icon. The actual data that the file contains is stored on your drive and won’t be deleted immediately. You still have time to bring it back!
Can you recover overwritten files?
Yes, you can recover overwritten files Mac has seemingly deleted. You can either use a backup tool or, for worst-case scenarios, a data recovery tool. There’s also a way to recover files from cloud backups if you use cloud storages such as Dropbox. The difficulty of the recovery task will depend on whether your macOS deletes the data referenced by the replaced file or not.
Where do replaced files go?
It really depends on the type of file, its size, your operating system, and many other factors. macOS was designed to save space on your drive and run all processes as fast as possible. This is why it will usually just delete the reference to your data to complete the task you want to complete — ”replace file.” The data that is actually referenced by that file, such as an image or the content of a PDF report, will be deleted at some point in the future — say, when you run an optimization task, clean up storage, etc.
You shouldn’t worry about how to find replaced files Mac has deleted. If you learn how to recover replaced files, you can bring them back — even if your macOS has deleted them. Next we cover three best ways to undo replace file Mac.
Recover an overwritten file on Mac with Time Machine
So let’s say you accidentally replaced file, how to recover? macOS allows you to roll back with a built-in tool. Time Machine is a brilliant macOS feature that’s designed to help you in situations where you’ve accidentally overwritten important files.
There is one caveat: Time Machine should’ve been active before you’d overwritten the file. If it was indeed, here’s how to get your file back.
How to recover overwritten files with Time Machine:
- Open the folder where the overwritten file was located in the Finder
- Select Enter Time Machine from the Time Machine menu (the clock icon) or click on its icon in the Dock
- Use the up arrow to travel back to a time before the file was replaced and locate the file
- Click on Restore and select which file you’d like to keep: the old one, the new one, or both
That’s it! Panic over. The old file is back.
Time Machine, however, is not the most flexible backup software you can use. It consumes a lot of space by storing a copy of every single file stored on your drive and works in preset intervals only.
For more flexible backups, try Get Backup Pro. This app also backs up your data but leaves you in charge of how exactly. You can choose different kinds of backups, like cloning or synchronization. You can also only back up folders and files that are of absolute importance, and ignore the rest. Get Backup Pro supports scheduled backups, so you can automate the process by setting up regular backups of the most essential data.
If, unfortunately, your Time Machine or Get Backup Pro were off when the overwriting took place (you should definitely turn them on now), your only hope for recovering files is using third-party software like Disk Drill. Fortunately, Disk Drill is very good at what it does.
Recovering replaced files on Mac via cloud backups
iCloud keeps your deleted files in a recovery folder for 30 days, so if you’ve just recently replaced a file, you can probably restore it via iCloud as an alternative to the backup method. To do this, go to iCloud.com > iCloud Drive. Go to your iCloud drive settings, scroll down to find Advanced, and click Restore files. Select a specific file you want to restore or all files.
If you use another popular cloud storage service — for example, Dropbox — there’s an option to restore overwritten files too:
- Go to dropbox.com and log in to your account
- Select the folder where your overwritten file is located or go to All files
- Once you’ve located the file, click the three dots > Version history
- Find the original version and click Restore.
Since Dropbox allows you to store up to 2 GB of files for free, it will normally keep a pretty extensive version history. So the chances are, unlike iCloud, it will keep the originals of your files for more than 30 days.
Restore overwritten files with one click
How do I recover a replaced file on Mac if there’s no backup available and my cloud account hasn’t saved it? For sure, losing your files and not having a proper backup in place might almost ruin your day, but there is still one more thing left to do.
Meet Disk Drill — a top-rated tool that has recovered millions of overwritten files from Macs, external hard drives, memory cards, and USB drives worldwide. This app is easy to use and can recover documents, photos, videos, music, or anything else you might’ve lost.
Here’s how to get your overwritten file back with recovery software:
- If the file is on an external drive, make sure to connect it first. Launch Disk Drill and enter your administrator password to give the tool permission to scan your drive
- Select the drive you wish to recover the file from, locate the file, and click on the Recover button
- Grab a coffee and sit back while Disk Drill does its thing to bring your file back to life.
If the Recover option can’t be used, Disk Drill is able to perform a Quick Scan and Deep Scan to scan drives at a binary level to restore files that way. However, for overwritten files, this is unlikely to be needed.
With a good backup and recovery tool, you can learn how to undo “replace file Mac” in seconds. So don’t panic if you accidentally overwrite something important, the chances are you’ll get it back with ease. Other than that, make it a habit to backup your files regularly — not only to avoid overwriting, backups will help you restore your data in case your drive fails, your macOS update goes wrong, or else.
Even when Time Machine or Get Backup Pro is activated, we recommend having Disk Drill around, just for peace of mind. Should anything go wrong with any file, all is not lost, and you have three ways to recover. Best of all, both Get Backup Pro and Disk Drill come together, along with more than 200 apps, in one Setapp subscription. And you can try them absolutely free.