--- title: "BorgBackup" category: "Backup, files and security" tagline: "Deduplicating, compressed, encrypted backups to a disk or a server over SSH." source: "pacman" package: "borg" command: "borg" website: "https://www.borgbackup.org/" code: "https://github.com/borgbackup/borg" links: - name: "Borg documentation" url: "https://borgbackup.readthedocs.io/" --- ## What it is BorgBackup, or Borg, makes backups into a repository on a local disk or on a server you reach over SSH. Each backup is a full snapshot you can browse or mount, but Borg stores only the chunks of data that changed, so daily backups take little extra space. Data is compressed and can be encrypted before it leaves your machine. ``` borg create /mnt/usb/borg::{now} ~/Documents ``` ## Why it's here - **Space-efficient.** Deduplication means a year of daily backups can fit where a few full copies would. - **Encrypted.** Repositories can be encrypted with a key only you hold. - **Good for your own backups.** To a USB drive, a NAS or any server with SSH. ## On CoreDesktop Borg is installed from pacman for backups you set up yourself. CoreDesktop's own daily [backups](/utilities/#backups) use [restic](/software/restic/) instead, so Borg doesn't run unless you use it. The [AI sandbox](/ai-sandbox/) keeps agents out of `~/.config/borg`, where Borg keeps its keys. `update` keeps it current with the rest of the Arch packages.