Transfer Docker images without a registry

Save image archives, transfer and verify them, then load the intended tags and platform variants on another host.

Best practices
Illustration of server operations and log analysis

Use docker image save on the source host and docker image load on the destination. The archive carries image layers and configuration, making this useful for isolated environments or occasional transfers without a registry.

Save, transfer, and load

# Source host
docker image save -o myapp_1.2.tar myapp:1.2
sha256sum myapp_1.2.tar
scp myapp_1.2.tar user@target-host:/tmp/

# Destination host
sha256sum /tmp/myapp_1.2.tar
docker image load -i /tmp/myapp_1.2.tar
docker image inspect myapp:1.2

Compare the hashes through a trusted channel before loading. On macOS, shasum -a 256 is a common alternative. A checksum detects a changed transfer; an untrusted archive and its accompanying untrusted checksum do not establish authenticity.

Use a name:tag reference when exporting so the intended repository tag is included. Confirm the image ID, tags, and platform after loading rather than relying on a text search over a broad image listing.

Bundle images or stream the transfer

docker image save -o bundle.tar myapp:1.2 nginx:stable redis:7

Use the exact versions your deployment requires. To avoid an intermediate archive, a Bash pipeline can compress and stream over SSH:

set -o pipefail
docker image save myapp:1.2 | gzip | ssh user@target-host 'docker image load'

load accepts gzip-compressed input. Confirm the pipeline succeeds and inspect the result remotely. A saved archive is easier to retry and verify independently when the connection is unreliable.

Keep image transfer separate from data migration

save/load preserves the image representation. export/import moves a flattened container filesystem and does not preserve the same image history and configuration. The save/load workflow does not include a container's writable-layer changes or mounted volume data, and it does not migrate host-side deployment configuration. Handle secrets and persistent data through their intended migration process.

Current save exports platform variants present in the local image store, not necessarily only the host's architecture. On versions supporting --platform, select a particular variant explicitly; it must already be present locally. Loading an archive does not convert an amd64 executable into an arm64 executable. Use a compatible variant or deliberately configured emulation.

FAQ

Why did the image appear without a useful tag?

The archive may not include the expected repository tag, for example when exported by ID. Inspect the loaded object and assign the intended name with docker tag IMAGE_ID myapp:1.2 after confirming its identity.

Are existing layers duplicated?

Docker can reuse identical content already stored locally. Disk usage is not simply the sum of each image's displayed size because images can share layers.

Is this suitable for continuous distribution?

For many hosts or frequent releases, a registry provides a more manageable distribution workflow. Archive transfer remains useful for small or disconnected deployments.

See image save and image load.

Get a tailored plan

Contact us

Join the community

Scan with WeChat
to join the community

Try Guance

Start online and pay only for what you use.

Get started

Choose a Guance plan

Code hosting