Own It

Backing Up Your Local AI Setup

What's actually worth backing up in a local AI setup, and how to back up and restore an Open WebUI Docker volume without losing anything.

11 minute read
Last tested: August 2026 · Docker 29.7.2

What actually needs backing up

A local AI setup has a mix of things that are trivial to recreate and things that genuinely aren't. Getting this distinction right saves you from wasting space backing up the wrong stuff, and from losing the stuff that actually matters.

Don't bother backing up: the model weight files themselves. They're large, and pulling them again is one command and a few minutes - re-downloading is faster than most backup-and-restore processes anyway. It's still worth saving a quick list of exactly which ones you have, so recreating the set is fast rather than trying to remember:

ollama list > ollama-models.txt
A model tag isn't necessarily frozen forever. Pulling llama3.2 again next year isn't guaranteed to fetch byte-identical weights to what you have today - tags can get updated. If exact reproducibility genuinely matters for something, record the model's digest (ollama list shows it), quantization, and the date you pulled it, not just the tag name.

Do back up:

  • Your Open WebUI chat history and settings - see What Happens to Your Data for where this actually lives
  • Any Modelfiles you've written for custom system prompts (see Persistent Instructions With Ollama Modelfiles) - small text files, but not stored anywhere that survives a full reinstall
  • The original source documents behind any RAG knowledge collections (see Talking to Your Own Documents with RAG) - the indexed copy inside Open WebUI is rebuildable from these, so the originals are what actually matter
  • If you're running OpenClaw, the ~/.openclaw/workspace/ directory - the memory files it reads on every turn

Backing up Open WebUI

Your chat history lives in a Docker volume, not a folder you can just copy directly. Stopping the container briefly first is the safer default - it takes a few seconds, and it means the backup can't catch the database mid-write:

docker stop open-webui
docker run --rm -v open-webui:/data -v $(pwd):/backup alpine \
  tar czf /backup/open-webui-backup.tar.gz -C /data .
docker start open-webui

The middle command starts a temporary throwaway container that mounts your actual data volume, packs it into a compressed archive, and saves that archive to your current folder - then removes itself.

The result: a single file, open-webui-backup.tar.gz, containing your full chat history and settings. Move that file anywhere - an external drive, cloud storage - the same way you'd back up any other file.

Restoring from a backup

If you're restoring onto a fresh install, create the volume first by running Open WebUI's normal install command once (see Getting a Proper Chat Interface Running), then stop it and restore the archive into that same volume:

docker stop open-webui
docker run --rm -v open-webui:/data -v $(pwd):/backup alpine \
  tar xzf /backup/open-webui-backup.tar.gz -C /data
docker start open-webui

Your chat history and settings come back exactly as they were at backup time.

What actually goes wrong

The backup file is tiny, way smaller than expected

Double-check the volume name in the command actually matches yours - docker volume ls lists what's really there. A typo in the volume name silently archives an empty or wrong volume instead of erroring out.

The backup is sitting on the same drive as everything else

A backup that lives on the same machine, same drive, protects against almost nothing - if that drive fails, both copies are gone at once.

Copy the archive to an external drive (see the external SSD pick) or a cloud storage folder you already use for other backups.

Skipping the stop/start step to avoid the brief downtime

Backing up without stopping the container first is low-risk for a quiet single-user setup, but not zero-risk - a rare bad-timing snapshot could catch the database mid-write. The few seconds of downtime from the default procedure above is cheap insurance against that; skip it only if you specifically can't tolerate even that short interruption.

A power outage corrupts something, not a backup timing issue at all

The same mid-write risk above applies any time the machine loses power unexpectedly, not just during a manual backup - if Open WebUI's database is mid-write when the outage hits, you can end up with a corrupted volume even with good backup habits. A UPS is cheap insurance for exactly this on a machine that's running unattended most of the time.

Common questions

Do I need to back up my models?
No. Models are large, freely re-downloadable, and identical every time you pull them - backing them up just wastes storage space for something you can recreate with one command.
How often should I actually do this?
Monthly is reasonable for casual use. If you're actively building out RAG document collections or custom Modelfiles, back up right after a session where you added something you'd be annoyed to redo.

Go deeper

This guide covers backing up the core setup. Here's where to go if you want something different.

Changelog

  • 2026-08-31: Made stopping the container before backup the default procedure instead of an optional footnote, added a model-inventory export step, and added a note that model tags aren't guaranteed byte-identical forever.
Keep exploring See everything else worth knowing, whenever you actually want it.
Explore more guides →

Written from hands-on security operations experience. More about this site →