Docker save: write images to a tar archive
Answer: docker save produces a tarred repository to the standard output stream. The alias docker image save is the same command. Use the --platform option to specify which platform variant of the image to save. The -o option writes to a file, instead of STDOUT.
Examples
docker save -o backup.tar myimage:1.0
docker image save --platform linux/amd64 myimage
Notes
The archive contains all parent layers, and all tags plus versions, or a specified repo:tag, for each argument provided. Architecture and variant are optional, and default to the daemon native architecture if omitted. The resulting archive can be used with docker load.
Reference list
savewrites a tarred repository to standard output.platform--platform selects which image variant to save.
See also
Claims
- id: C1 claim: save writes a tarred repository to standard output. source: S1 evidence: "Produces a tarred repository to the standard output stream"
- id: C2 claim: --platform selects which image variant to save. source: S1 evidence: "Use the --platform option to specify which platform variant of the image to save"
- id: C3 claim: The CLI page describes a backup that docker load can read. source: S2 evidence: "Create a backup that can then be used with
docker load"
Sources
- [S1] docker image save. Docker docs. https://docs.docker.com/reference/cli/docker/image/save/ . License: Apache-2.0. Accessed 2026-11-18.
- [S2] image save reference. docker/cli. https://github.com/docker/cli/blob/master/docs/reference/commandline/image_save.md . License: Apache-2.0. Accessed 2026-11-18.
License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources: Docker docs, docker image save; docker/cli, image save reference. Apache-2.0 (https://raw.githubusercontent.com/docker/docs/main/LICENSE). Copyright Docker, Inc. Apache-2.0 (https://raw.githubusercontent.com/docker/cli/master/LICENSE). Copyright Docker, Inc. Text was condensed and changed from the originals.
License: CC-BY-4.0 · Summary by iinventedlight (AI-assisted). Sources: Docker docs, docker image save; docker/cli, image save reference. Apache-2.0 (https://raw.githubusercontent.com/docker/docs/main/LICENSE). Copyright Docker, Inc. Apache-2.0 (https://raw.githubusercontent.com/docker/cli/master/LICENSE). Copyright Docker, Inc.
Cite this
iinventedlight. 2026. "Docker save: write images to a tar archive." iinventedlight Library, iil:note:zd2w2dxg, version of 2026-11-18. https://iinventedlight.com/library/notes/docker-save/. License: CC-BY-4.0.
@misc{iil_note_zd2w2dxg,
author = {{iinventedlight}},
title = {{Docker save: write images to a tar archive}},
howpublished = {iinventedlight Library},
year = {2026},
date = {2026-11-18},
url = {https://iinventedlight.com/library/notes/docker-save/},
note = {Permanent ID iil:note:zd2w2dxg. License: CC-BY-4.0.},
}
Spotted a mistake? Use the MCP feedback tool or email hello@iinventedlight.com. Or Report a correction (no account needed).
For language models and agents: start at /llms.txt | /agents.md | /.well-known/agent-library.json. This page in Markdown: /library/notes/docker-save.md.