Guideschevron_rightStorage

Storage · 7 min read · Updated

Borg Backup to S3, Backblaze B2 or Wasabi

Borg 1.x, the stable series, cannot write to S3, Backblaze B2 or Wasabi: its repositories live on a local disk or on a server reached over SSH. You have four workable options. Back up to an SSH storage box, which Borg supports natively. Keep a local Borg repository and copy it to a bucket with rclone sync after each run. Use restic or Kopia, which write to S3 directly. Or try Borg 2, whose betas add S3 and B2 repositories but are not yet meant for production backups.

The Options Side by Side

Ways to get Borg-style backups into cloud storage
AspectHow it worksGoodWatch out for
Borg to an SSH storage boxborg talks to borg serve over SSHNative, no extra steps, efficient incremental uploadsNeeds an SSH target, not a bucket
Borg locally, then rclone syncBack up to a local repo, copy it to S3Works with any bucket; Borg unchangedNeeds local disk for the whole repo; sync must not overlap backups
restic or KopiaEncrypted, deduplicated backups straight to S3Made for object storageA different tool and repository format
Borg 2 betas3: and b2: repositories built inNative S3 supportBeta: the project says not for production; repos not compatible with 1.x

Option 1: Borg to an SSH Storage Box

The simplest route keeps Borg exactly as it is designed to run. A storage box accepts Borg over SSH, so the repository lives off the server and only new data is uploaded each night:

borg init --encryption=repokey ssh://USER@HOST:23/./borg
borg create --stats ssh://USER@HOST:23/./borg::{now} /etc /srv /home
borg prune --keep-daily 7 --keep-weekly 4 --keep-monthly 6 ssh://USER@HOST:23/./borg

Backing up a Linux server with Borg covers keys, a nightly timer and a test restore.

Option 2: Local Repository, Then rclone

If the copy must end up in S3, Backblaze B2 or Wasabi, back up to a local repository and copy it to the bucket afterwards. Do the steps in order, so the bucket never receives a repository halfway through a write:

borg create --stats /srv/borg-repo::{now} /etc /srv/www /home
borg prune --keep-daily 7 --keep-weekly 4 /srv/borg-repo
borg compact /srv/borg-repo
rclone sync /srv/borg-repo remote:my-bucket/borg-repo --checksum

rclone sync makes the bucket match the local repository, including deletions, so a damaged local repository would be copied too. Run borg check regularly, and if the bucket supports versioning or retention locks, turn them on. To restore, copy the repository back with rclone copy and run borg extract as usual. The rclone side is covered in using object storage with rclone.

Option 3: restic or Kopia Straight to S3

restic and Kopia work much like Borg (encrypted, deduplicated snapshots with retention rules) but write to S3-compatible storage directly, with no local copy:

export AWS_ACCESS_KEY_ID=YOUR_KEY AWS_SECRET_ACCESS_KEY=YOUR_SECRET
export RESTIC_REPOSITORY=s3:https://S3_ENDPOINT/my-bucket/server1
export RESTIC_PASSWORD_FILE=/root/.restic-password
restic init
restic backup /etc /srv/www /home
restic forget --keep-daily 7 --keep-weekly 4 --prune

Borg vs restic vs Kopia vs rclone compares them in detail.

Option 4: Borg 2

Borg 2 adds repositories on S3, Backblaze B2 and anything rclone supports, through its new storage layer. As of September 2026 it is still in beta (2.0.0b25), and its release notes ask users not to use it for production backups. Its repositories are also a new format that Borg 1.x cannot read. It is worth testing on a spare bucket, not yet worth trusting with the only copy of your data.

Amazon S3, Backblaze B2 and Wasabi are trademarks of their respective owners. Virteche is not affiliated with or endorsed by them. Details about their products come from their public documentation as of the date at the top of this guide.

Common Questions

  • Does Borg support S3?

    Not in the stable 1.x series (1.4.5 as of July 2026), which stores repositories on a local path or on a remote server over SSH. The Borg 2.0 betas add S3, Backblaze B2 and rclone repositories, but the project marks them as testing only and not for production backups.

  • Can I mount an S3 bucket and point Borg at it?

    It can be made to work with rclone mount, but it is slow and fragile: Borg expects a real file system with reliable locking and renames, which a bucket only imitates. A local repository synced afterwards, or a different tool, is far more dependable.

  • Is it safe to rclone sync a Borg repository?

    Yes, if the repository is not being written to at the time. Run the sync after borg create, prune and compact have finished, never alongside them, and check the repository with borg check before relying on the copy.

  • Should I switch to restic instead?

    If your backups must go straight to S3-compatible storage, restic or Kopia are the natural choice: both write to S3 natively, deduplicate and encrypt like Borg. If you can use an SSH target such as a storage box, Borg 1.x remains an excellent option.

Storage boxes speak Borg natively over SSH on port 23, with snapshots and a flat monthly price. Object storage is there for restic and Kopia.

See storage boxes

Keep Reading

All guides