How to restore a folder to a previous version on Mac
You changed a folder and want it back the way it was an hour ago: a script renamed everything, an app rewrote your files, or an AI agent cleaned up a little too much. macOS has a few ways to go back, and they work very differently. All steps were checked on macOS 27.0.1.
Option 1: Time Machine
If Time Machine backs up your Mac, it can bring back a folder as it was at any backup.
- In Finder, open the folder that contains the one you want back.
- Click Time Machine in the menu bar and choose Browse Time Machine Backups, or open Time Machine from the Applications folder.
- Use the arrows or the timeline on the right to go back to a time before the change.
- Select the folder and click Restore.
If a folder with the same name is still there, Finder asks whether to keep the original, keep both or replace it. Keeping both is the safe choice: compare them, then delete the one you don’t want.
The limits: you only get the moments Time Machine happened to back up. Apple says it keeps hourly backups for the past 24 hours, daily ones for the past month and weekly ones before that, plus local snapshots on the Mac’s own disk for up to 24 hours. If Time Machine isn’t set up, there’s nothing to go back to. Restoring a big folder from an external disk also takes a while.
Option 2: document versions
Apps that save document versions, such as TextEdit, Pages, Numbers, Keynote and Preview, can go back on their own:
- Open the document.
- Choose File > Revert To > Browse All Versions…
- Pick a version and click Restore.
This works one document at a time and only in those apps. It can’t put back a folder, files that were deleted or renamed, or files from apps that don’t keep versions, such as code editors.
Option 3: git
If the folder is a git repository and you committed before the change:
git status
git restore .
That returns every tracked file to the last commit. Deleted files that git never tracked, and folders that aren’t repositories, aren’t covered.
Option 4: snapshot the folder first
The most reliable undo is the one you take right before a risky change. On APFS, the Mac’s file system, a clone copies a folder in seconds and shares its data with the original, so it takes almost no space at first.
By hand, with cp -c
cp -c -R ~/Projects/Aurora ~/Projects/Aurora-before
To go back, move the changed folder to the Trash and rename Aurora-before to Aurora. It works, but you’d have to compare the folders yourself to see what changed, and old copies stay until you delete them.
With Mulligan
Mulligan does the same with one click, from its menu bar item, from Finder’s Take a Mulligan Quick Action or from the command line. Later it lists every file that changed, was removed or was added, and puts back the whole folder or only the files you select. Replaced versions go to the Trash, and putting back a whole folder first saves its current state, so you can undo the undo.
In our tests on macOS 27.0.1, saving 20,000 files plus a 1 GB file took 2.0 seconds and about 8 MB of extra space. Time grows with the number of files, not their size.
A snapshot like this lives on the same disk as the folder. It’s an undo point, not a backup: keep Time Machine for the day a disk fails.
Which one to use
| Time Machine | Document versions | git | Folder snapshot | |
|---|---|---|---|---|
| Whole folders | Yes | No | Tracked files | Yes |
| Deleted and renamed files | Yes | No | Tracked files | Yes |
| Exactly the moment before the change | Only if a backup ran then | Saves as you work | If you committed | Yes, you take it |
| Speed | Minutes from an external disk | Instant | Instant | Seconds |
| Protects against disk failure | Yes | No | Only if pushed | No |
Questions
Can I restore a folder on Mac without Time Machine?
Only if you saved a copy before it changed. Documents in apps like TextEdit, Pages and Preview keep their own versions (File > Revert To > Browse All Versions), and git restores tracked files in a repository. For any folder, copy it with cp -c or take a snapshot with an app like Mulligan before you change it.
Does restoring from Time Machine overwrite the current folder?
Not without asking. If a folder with the same name is still there, Finder asks whether to keep the original, keep both or replace it. Keeping both is the safest choice.
Does a copy made with cp -c take double the space?
No, not at first. On APFS, cp -c makes a clone that shares its data with the original. Space is used only as files change. On a disk that can't clone, cp falls back to a normal copy.