Back up your iCloud Photos
to your storage

Keep using Photos.app like you always do. Attic quietly backs up your originals and edits to an S3 bucket you control. One-way, append-only. A safety net, not a second photo manager.

View on GitHub See how it works ↓
brew install tijs/tap/attic

What Attic does

Attic is a command-line tool that backs up your iCloud Photos library to S3-compatible object storage. It exports original and edited files via PhotoKit and uploads them with full metadata. Incremental by default — it only uploads what's new.

i.

Originals & edits

Exports both the original and the edited version of your photos and videos. No recompression, no quality loss. What you shot — and what you made of it — gets stored.

ii.

Full metadata

Each asset is uploaded alongside a JSON file with EXIF data, dates, location, album membership, dimensions, and file hashes.

iii.

Incremental

A local manifest tracks what's been backed up. Subsequent runs skip known assets and only upload what's changed or new.

iv.

Verifiable

A built-in verify command checks S3 objects against the manifest. Run it with --deep to re-check SHA-256 hashes on every file.

How it works

Attic is a standalone macOS binary that orchestrates a four-step pipeline. It uses PhotoKit directly to export photos and videos from your library, then uploads them to your S3 bucket.

1

Scan

Reads Photos.sqlite to discover all assets, their types, sizes, and iCloud status.

2

Diff

Compares the database against the local manifest to find assets that haven't been backed up yet.

3

Export

Uses PhotoKit to export original and edited files to a staging directory.

4

Upload

Uploads each original + metadata JSON to your S3 bucket, then updates the manifest.

Credentials

S3 access keys are stored in the macOS Keychain. Never in config files, never in environment variables. The config file only holds the endpoint, region, and bucket name.

iCloud-only assets

If a photo or video isn't downloaded locally, Attic requests it from iCloud via PhotoKit. This means it can back up your entire library, not just what's on disk.

What you need

A Mac

Attic uses Photos.sqlite and the macOS Keychain. It runs on any Mac with a Photos library — your daily driver or a dedicated machine.

Homebrew

Install Attic with brew install tijs/tap/attic. It's a standalone binary — no runtime dependencies.

An S3 bucket

Any S3-compatible provider works. Create a bucket, generate API keys, and run attic init to configure.

Pick your provider

Any S3-compatible storage works. If you want your backups in the EU, these are solid options. If you already have AWS, that works too.

Honest expectations

It does

  • Back up original and edited photos and videos to S3
  • Preserve full metadata (EXIF, location, albums, dates)
  • Run incrementally — only upload what's new
  • Verify backups with checksum validation
  • Store credentials in macOS Keychain
  • Fetch iCloud-only assets via PhotoKit
  • Run unattended on a spare Mac

It doesn't

  • × Replace iCloud Photos — it's a backup, not a sync
  • × Have a GUI — it's a command-line tool
  • × Run on Windows or Linux
  • × Require any runtime dependencies
  • × Restore photos into your library
  • × Browse or view your backed-up photos
  • × Manage your storage bucket for you

Commands

Everything runs through the attic command. Set up once, then it's just attic backup and occasionally attic verify.

init Interactive setup. Configures S3 connection and stores credentials in Keychain.
scan Read the Photos library and print stats: asset counts, sizes, types, local vs iCloud-only.
status Compare library against manifest. Shows how many assets are backed up vs pending.
backup Export pending assets and upload originals + metadata to S3. Supports --dry-run, --limit, and --type filters.
verify Check S3 objects against the manifest. Use --deep to re-verify SHA-256 checksums.

Put that Mac mini to work

Got a Mac mini sitting around after your OpenClaw experiments? Sign into iCloud Photos on it and let Attic run daily backups via launchd. See the unattended backups guide for the full setup.

# crontab -e
# Run backup daily at 3am
0 3 * * * attic backup

# Verify weekly on Sundays
0 4 * * 0 attic verify