All articles

How to Keep Two Folders in Sync on a Mac

· 6 min read

The Finder has no way to keep two folders in sync. You can copy a folder to an external disk or a NAS once, but nothing updates that copy when files change, and nothing removes what you deleted. To keep two folders matched you need either the rsync command in Terminal or an app with a sync tool. Before you pick one, decide which kind of sync you want, because one of them deletes files.

Copy or mirror: decide this first

A one-way sync always runs from a source (the folder you work in) to a destination (the disk, NAS or server that holds the copy). There are two ways to do it:

  • Copy: new and changed files go to the destination. Nothing is ever deleted there. If you delete a file in the source, the old copy stays at the destination. It is the safe choice for an archive.
  • Mirror: the destination becomes an exact copy of the source. Files you delete in the source are deleted at the destination too. It keeps the copy tidy, but a mistake in the source (or a source that turns out empty) spreads to the destination.

A mirror is not a backup. If you delete or damage a file in the source, the next run carries the damage over. If you need to get back yesterday's version of a file, you want dated backups, not only a sync (more on that at the end).

The built-in way: rsync in Terminal

macOS includes rsync, a command-line tool that copies only what changed. A copy-style sync from a projects folder to a mounted NAS share looks like this:

rsync -av ~/Projects/ /Volumes/NAS/Projects/

To make it a mirror, add --delete. Always run it first with --dry-run (or -n), which lists what would happen without touching anything:

rsync -av --delete --dry-run ~/Projects/ /Volumes/NAS/Projects/

It works, but it has sharp edges:

  • The trailing slash matters. ~/Projects/ copies the folder's contents; ~/Projects (without the slash) creates a Projects folder inside the destination. Getting it wrong puts files in the wrong place, and with --delete it can remove files you wanted to keep.
  • No safety net. --delete removes files permanently, without going through the Trash and without asking. If the source is empty because a disk did not mount or the path is wrong, the mirror empties the destination.
  • Scheduling is up to you. Running it every hour or when files change means writing a launchd job or a cron entry, and checking its logs yourself.

If you are comfortable in Terminal and test with --dry-run every time, rsync does the job. If you want the same result with visible settings and checks before anything is deleted, use a sync tool.

Sync two folders with Folia Files

Folia Files has a sync tool built in. It runs one-way syncs between two folders: a local folder, an external disk, a mounted NAS share or server, or a cloud remote through rclone.

The Sync tool in a Folia Files tab: a saved sync copies the Iceland 2026 folder to pCloud every day at 20:00, by checksum; the list on the left shows its last run, 2 hours ago

Set up a sync

  1. Choose Tools › Sync… (⇧⌘Y). The tool opens in a tab.
  2. Click New Sync, then set the Source and the Destination with Choose…, or drag a folder onto each card.
  3. Under the destination type, pick Folder (disk, volume, mount) for a disk or a mounted share, or Cloud via rclone to send files to a cloud remote without mounting it. That option needs rclone, which you install separately (for example with Homebrew).
  4. Choose the Mode: Copy (additions and changes) or Mirror (identical destination). Then decide what happens to items removed or replaced at the destination: Move to Trash or Delete Permanently.
  5. Choose the Comparison:
    • Size and Date (fast): a file is copied again when its size or modification date differs, as rsync does by default.
    • Content Checksum (exact): files of the same size are compared by their SHA-256 fingerprint, so an identical file is never copied again just because its date changed. Fingerprints are remembered, so later runs only read what moved.
  6. Choose When: Manually, At Regular Intervals, Every Day at a set time, or Whenever the Source Changes. Add Exclusions if needed, separated by commas (node_modules, *.log, .git).
  7. Click Dry Run to see what the sync would do: new files, updated files, deletions and conflicts, with the amount of data to transfer. Then click Sync Now.

Scheduled and on-change syncs only start after a first run that you launch yourself with Sync Now. They run while Folia Files is open; the Open Folia Files at login switch in the tool keeps them going after a restart. Each saved sync appears in the list on the left with its schedule and the time of its last run; a green check means that run went well.

What happens before anything is deleted

The risky part of a mirror is deletion, so Folia Files checks before it removes anything:

  • No mirror from an empty or missing source. If the source has no files while the destination has some, or if the source's disk is not mounted, the sync is blocked. It also refuses a source and a destination that overlap, and a mirror into the root of a cloud remote.
  • You confirm the real number. A manual mirror run that would delete files asks first, with the number of files and where they go (Trash or permanent deletion), and the button says Sync and Delete. The first time a mirror deletes in a destination, the dialog says so: everything that is not in the source is removed, even files the sync did not put there.
  • Scheduled runs do not delete on their own. An automatic mirror run is skipped and reported if it would delete in a destination where you have never confirmed a deletion, or if it would remove more than half of the destination's files. You run it once by hand to confirm.
  • Nothing is deleted when something could not be read. If a folder of the source is unreadable during a run, the run copies what it can and deletes nothing.
  • Newer files at the destination are kept. With a folder destination, a file that was modified at the destination (newer than in the source) is not overwritten; it is listed as a conflict.

The Copy mode never deletes anything at the destination.

Website edition and Mac App Store edition

Folia Files comes in two editions, and sync differs between them:

  • Website edition: the Sync tool is there, with folder and cloud destinations.
  • Mac App Store edition: sync is one of the things added by Folia Files Companion, a free helper app. The Sync tool appears once the companion is installed and active; without it, the Sync… item is not in the menu. With the companion, folder syncs and cloud syncs through rclone are available (cloud syncs run inside the companion, and rclone must still be installed).

Backups (Tools › Backups…) work in both editions without the companion, to a disk or a NAS.

Sync or backup? Check before you trust it

A sync gives you one current copy. If you need earlier versions of your files, use Backups, which keeps dated copies of the folders you choose on a disk or a NAS; unchanged files take no extra room. Many people use both: a mirror to keep a working copy on the NAS, and backups to go back in time.

To check that a copy really matches its source, open Tools › Compare… and compare the two folders: files added, removed and changed are listed side by side.

The Compare tool showing the differences between two folders

If the destination is a server or a cloud you do not mount, see how to connect to SFTP and S3 on a Mac without macFUSE.