How To

Borg vs Restic vs Kopia: Backup Tools Benchmarked

Three backup tools dominate the open-source Linux backup space: BorgBackup, Restic, and Kopia. All three offer deduplication and encryption. All three have loyal communities insisting theirs is the best. The internet is full of opinions, but few comparisons include actual benchmark numbers. This one does.

Original content from computingforgeeks.com - post 165101

We installed all three on the same Ubuntu 24.04 VM, pointed them at the same 370 MB test dataset, and measured first backup speed, incremental performance, restore time, memory usage, and repository efficiency. The results reveal clear strengths for each tool, which should make your decision easier. If you already use one of these tools, check our dedicated guides for BorgBackup with Borgmatic, Restic with S3/SFTP, and Kopia on Linux and Windows.

Current as of March 2026. Benchmarked on Ubuntu 24.04.4 LTS with BorgBackup 1.2.8, Restic 0.16.4, and Kopia 0.22.3

Test Setup

Every benchmark ran on the same machine to keep things fair: Ubuntu 24.04.4 LTS, 2 vCPU, 4 GB RAM, 30 GB SSD. The test dataset was 370 MB spread across 1,957 files in four categories:

  • Small files: 1,000 files (1 to 10 KB each), 7.3 MB total
  • Medium files: 100 files (100 KB to 1 MB), 51 MB total
  • Large files: 10 files (10 to 50 MB each), 306 MB total
  • Mixed: a copy of /etc (839 regular files, 232 directories, 634 symlinks), 6.1 MB

Each tool used its default encryption setting. All backups went to a local filesystem repository to eliminate network variables. Every tool got a fresh, empty repository with no prior data. Wall-clock time was measured with /usr/bin/time -v, which also captured peak memory (maximum resident set size).

Tools and Versions Tested

Each tool was installed on the same Ubuntu 24.04 VM. For complete installation and usage instructions, see the dedicated guides:

All three tools were configured with their default encryption enabled and pointed at local filesystem repositories to eliminate network variables from the benchmarks.

First Backup Speed

The first backup is the most expensive. Every file must be read, chunked, compressed, encrypted, and written to the repository. This is where raw throughput matters.

BorgBackup: 7.81 seconds

Initialize a new encrypted repository, then back up the test data:

export BORG_PASSPHRASE="benchmarktest"
borg init --encryption=repokey /tmp/borg-repo
/usr/bin/time -v borg create /tmp/borg-repo::backup1 /home/testuser/testdata 2>&1 | grep -E "wall clock|Maximum resident"

Borg finished in 7.81 seconds wall clock. The archive summary shows the dedup engine at work:

Duration: 7.06 seconds
Number of files: 1957
                       Original size      Compressed size    Deduplicated size
This archive:              381.05 MB            379.81 MB            379.78 MB

With no prior data in the repo, deduplication saved almost nothing on the first run. The small gap between original and compressed size (0.3%) is expected because the test data is mostly random bytes.

Restic: 8.10 seconds

Initialize and run the first backup:

export RESTIC_PASSWORD="benchmarktest"
restic init --repo /tmp/restic-repo
/usr/bin/time -v restic backup --repo /tmp/restic-repo /home/testuser/testdata 2>&1 | grep -E "wall clock|Maximum resident"

Restic’s output is straightforward:

Files:        1957 new,     0 changed,     0 unmodified
Added to the repository: 364.299 MiB (362.204 MiB stored)
processed 1957 files, 363.401 MiB in 0:07
snapshot 60f9c70c saved

Total wall-clock time including overhead: 8.10 seconds. Very close to Borg.

Kopia: 4.65 seconds

Create a filesystem repository and run the backup:

kopia repository create filesystem --path /tmp/kopia-repo --password benchmarktest
/usr/bin/time -v kopia snapshot create /home/testuser/testdata 2>&1 | grep -E "wall clock|Maximum resident"

Kopia was noticeably faster:

Created snapshot with root k20adeb0165392df3c7971e12d47e2b12 in 4s

4.65 seconds. Kopia’s Go implementation with parallel hashing gives it a real edge on initial backups. It processed the same data nearly twice as fast as Borg and Restic.

First Backup Verdict

Kopia wins by a clear margin. Borg and Restic are nearly tied, with Borg slightly faster. On larger datasets (tens of GB), the gap would widen further because Kopia parallelizes hashing across CPU cores while Borg’s Python layer adds overhead per chunk.

Incremental Backup Speed

A second backup with zero file changes tests pure metadata scanning speed. This is the operation that runs most often in production, because most backup windows see only a small fraction of files changed.

BorgBackup: 0.70 seconds

Run a second backup against the same unchanged data:

/usr/bin/time -v borg create /tmp/borg-repo::backup2 /home/testuser/testdata 2>&1 | grep -E "wall clock|Maximum resident"

Borg recognized every file was unchanged and stored only 645 bytes of new metadata:

Duration: 0.28 seconds
                       Original size      Compressed size    Deduplicated size
This archive:              381.05 MB            379.81 MB                645 B
All archives:              762.11 MB            759.62 MB            379.93 MB

645 bytes for a duplicate snapshot. That is deduplication working exactly as designed.

Restic: 0.81 seconds

Same test with Restic:

/usr/bin/time -v restic backup --repo /tmp/restic-repo /home/testuser/testdata 2>&1 | grep -E "wall clock|Maximum resident"

Restic shows zero new data added:

Files:           0 new,     0 changed,  1957 unmodified
Added to the repository: 0 B   (0 B   stored)
processed 1957 files, 363.401 MiB in 0:00

0.81 seconds total. Slightly slower than Borg because Restic walks the file tree and checks each file’s metadata before deciding nothing changed.

Kopia: 0.28 seconds

Kopia’s incremental run:

/usr/bin/time -v kopia snapshot create /home/testuser/testdata 2>&1 | grep -E "wall clock|Maximum resident"

The output shows everything served from cache:

0 hashing, 0 hashed (0 B), 2594 cached (381.1 MB), uploaded 0 B
Created snapshot in 0s

0.28 seconds. Kopia’s aggressive caching means it barely touches the filesystem on unchanged data.

Incremental Verdict

Kopia is fastest again, but all three are sub-second. In practice, the difference between 0.28s and 0.81s is irrelevant for nightly backups. What matters is that all three correctly detected zero changes and stored essentially nothing new.

Restore Speed

Backup speed gets all the attention, but restore speed is what matters when your data is gone and your boss is watching. We restored the full snapshot to a temporary directory and timed it.

BorgBackup: 0.16 seconds

Restore with Borg:

mkdir /tmp/restore-borg
cd /tmp/restore-borg
/usr/bin/time -v borg extract /tmp/borg-repo::backup1 2>&1 | grep -E "wall clock|Maximum resident"

0.16 seconds. Borg’s streaming archive format reads sequentially through the repository, which is extremely fast for full restores.

Restic: 3.67 seconds

Restore with Restic:

/usr/bin/time -v restic restore latest --repo /tmp/restic-repo --target /tmp/restore-restic 2>&1 | grep -E "wall clock|Maximum resident"

3.67 seconds. Restic must reassemble files from individual content-addressed blobs, which adds overhead compared to Borg’s sequential read.

Kopia: 4.39 seconds

Restore with Kopia:

/usr/bin/time -v kopia restore k20adeb0165392df3c7971e12d47e2b12 /tmp/restore-kopia 2>&1 | grep -E "wall clock|Maximum resident"

4.39 seconds. Similar to Restic. Both Go-based tools use a content-addressed object store that requires more random reads during restore.

Restore Verdict

Borg dominates here. It restored the entire 370 MB dataset in 0.16 seconds, roughly 23x faster than Restic and 27x faster than Kopia. Borg’s archive format stores data in a sequential stream optimized for full restores. Restic and Kopia store data as individual content-addressed objects, which is more flexible (better for partial restores and cloud backends) but slower for full restores from local disk.

If fast disaster recovery from local repos is your priority, Borg has a commanding advantage.

Memory Usage

Peak resident set size (RSS) tells you how much RAM each tool actually needs. This matters on small VMs, containers, or shared hosts where memory is limited.

OperationBorgBackupResticKopia
First backup75 MB111 MB176 MB
Incremental (no changes)75 MB54 MB118 MB

Borg is the most memory-efficient overall. Its peak stayed at 75 MB regardless of operation, which makes sense because its Python runtime allocates a relatively fixed working set. Restic dropped to 54 MB on incremental backups because it skipped all the chunking buffers. Kopia consistently used the most memory, peaking at 176 MB for the first backup.

None of these numbers are concerning on a modern server with 4+ GB of RAM. But on a resource-constrained system (1 to 2 GB RAM, a Raspberry Pi, a small container), Borg is the safest choice. Kopia’s memory appetite could become a problem if you’re backing up very large datasets on tight hardware.

Repository Efficiency

How much disk space does each tool’s repository consume? We compared repo sizes after one snapshot and after two snapshots (with no file changes).

MetricBorgBackupResticKopia
Repo size (1 snapshot)363 MB364 MB365 MB
Repo size (2 snapshots, no changes)363 MB364 MB365 MB
Compression savings0.3%0.6%0.1%

All three are within 2 MB of each other. Deduplication works perfectly across the board: the second snapshot added essentially zero bytes to every repository. The minimal compression savings (under 1%) are expected because our test data is mostly random bytes generated with dd if=/dev/urandom. Random data doesn’t compress.

With real-world data (log files, configuration files, source code, database dumps), compression savings would be dramatically higher. Borg defaults to lz4 compression, Restic uses zstd, and Kopia supports multiple algorithms including zstd and s2. For text-heavy workloads, expect 40 to 70% compression ratios from all three tools.

Benchmark Results Summary

The full results in one table. Green highlights indicate the best performer in each row.

MetricBorgBackup 1.2.8Restic 0.16.4Kopia 0.22.3
First backup (wall clock)7.81s8.10s4.65s
Incremental, no changes0.70s0.81s0.28s
Restore (wall clock)0.16s3.67s4.39s
Repo size (1 snapshot)363 MB364 MB365 MB
Repo size (2 snapshots)363 MB364 MB365 MB
Peak memory, first backup75 MB111 MB176 MB
Peak memory, incremental75 MB54 MB118 MB
Compression saved0.3%0.6%0.1%
Encryptionrepokey (AES-256)AES-256 in CTR modeAES-256-GCM
Dedup methodContent-defined chunkingContent-defined chunkingContent-defined chunking (BUZHASH)
LanguagePython + CGoGo

Kopia leads in backup speed, Borg leads in restore speed and memory efficiency, and all three are nearly identical in storage efficiency. No single tool dominates every category.

Feature Comparison

Benchmarks only tell part of the story. The right tool depends on what features you need beyond raw speed. This matrix covers the capabilities that matter most in production.

FeatureBorgBackupResticKopia
EncryptionYes (AES-256)Yes (AES-256-CTR)Yes (AES-256-GCM)
DeduplicationYesYesYes
Compressionlz4, zstd, zlib, lzmazstd (auto)zstd, s2, pgzip, none
Cloud backendsNo (SSH only)S3, B2, Azure, GCS, SFTPS3, B2, Azure, GCS, SFTP, Rclone
SSH backupYes (native)Via rcloneVia SFTP
Append-only modeYesYesACL-based
GUIVorta (desktop client)NoYes (web UI on :51515)
Wrapper toolBorgmaticNone neededBuilt-in policies
Active developmentYes (Borg 2.0 in development)YesYes
LanguagePython + CGoGo
Mount as filesystemYes (FUSE)Yes (FUSE)Yes (FUSE)
Windows supportNo (WSL only)YesYes
Built-in schedulingNo (use systemd/cron)No (use systemd/cron)Yes (kopia server)
Retention policiesManual (borg prune)Built-in (forget –keep-*)Built-in (policy set)

The biggest differentiator is backend support. BorgBackup only talks to SSH remotes. Restic speaks natively to every major cloud provider. Kopia matches Restic’s backend support and adds a built-in web UI, scheduling, and policy management that the other two lack.

When to Pick Each Tool

Pick BorgBackup when SSH is your only transport, you want the fastest restores, and memory is tight. It’s the oldest and most battle-tested of the three. Pair it with Borgmatic for automated scheduling and retention, because Borg itself has no built-in scheduler. If you prefer a graphical interface, Vorta is an open-source desktop client for macOS and Linux that wraps Borg with profiles, scheduled backups, and point-in-time restore browsing (install instructions). Borg’s restore speed advantage is significant enough that disaster recovery scenarios alone can justify the choice.

Pick Restic when you need native cloud storage support (S3, Backblaze B2, Azure Blob, Google Cloud Storage) without extra tools or wrappers. Restic has the simplest CLI of the three. One binary, straightforward commands, no configuration files required. The Restic community is large and active, so finding help is easy.

Pick Kopia when you want a single binary that handles everything: scheduling, retention policies, a web UI, and cloud backends. It’s the fastest for initial backups and the most feature-complete out of the box. No wrapper scripts, no systemd timers, no third-party tools needed. The tradeoff is higher memory usage and a younger project with a smaller (but growing) community.

All three are production-grade. They all encrypt, deduplicate, and compress. They all support FUSE mounting for browsing snapshots. You won’t regret choosing any of them. The benchmarks show that performance differences exist, but they’re small enough that features and workflow preferences should drive your decision more than raw speed numbers. If you want a fourth option that prioritizes a GUI-first experience, consider Duplicati, though it lacks the dedup performance of these three.

Related Articles

Storage Configuring GlusterFS on Ubuntu 22.04 With Heketi Security How To Run OpenLDAP Server in Docker Containers Networking Install WireGuard VPN Server on Ubuntu 24.04 | 22.04 Security 5 Ways to Avoid Becoming a Victim of Phishing Attacks

2 thoughts on “Borg vs Restic vs Kopia: Backup Tools Benchmarked”

Leave a Comment

Press ESC to close