Commands.app

rsync

Networking

Efficiently sync files and directories between locations

Options & Flags
Available options for this command
-a

Archive mode (preserves permissions, times, etc.)

-v

Verbose output

-z

Compress data during transfer

--delete

Delete files in destination not in source

Examples
Common usage examples

Sync directories with compression

rsync -avz source/ destination/

Sync from remote to local

rsync -avz user@remote:/path/ /local/path/

Mirror source to backup (delete extra files)

rsync -avz --delete source/ backup/
Notes
  • More efficient than scp for repeated transfers
  • Only transfers changed files
Related Commands
You might also find these useful