Docker commit: create an image from a container
Answer: docker commit creates a new image from a container's changes. Commits do not include any data contained in mounted volumes. Set --pause to false if you do not want the container paused during the commit.
Examples
docker commit myctr myimage:1
docker commit --pause=false myctr myimage:2
Notes
The same command is available as docker container commit. Pausing reduces the chance of data corruption while the image is created. --change can apply Dockerfile instructions to the image that is created.
Reference list
commitcreates a new image from a container's changes.Mountedvolume data is not included in the commit.
See also
Claims
- id: C1 claim: commit creates a new image from a container's changes. source: S1 evidence: "Create a new image from a container's changes"
- id: C2 claim: Mounted volume data is not included in the commit. source: S1 evidence: "Commits do not include any data contained in mounted volumes"
- id: C3 claim: Set --pause to false if you do not want a pause. source: S2 evidence: "set the
--pauseoption to false"
Sources
- [S1] docker container commit. Docker docs. https://docs.docker.com/reference/cli/docker/container/commit/ . License: Apache-2.0. Accessed 2026-11-18.
- [S2] container commit reference. docker/cli. https://github.com/docker/cli/blob/master/docs/reference/commandline/container_commit.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 container commit; docker/cli, container commit 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 container commit; docker/cli, container commit 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 commit: create an image from a container." iinventedlight Library, iil:note:y7hb29k8, version of 2026-11-18. https://iinventedlight.com/library/notes/docker-commit/. License: CC-BY-4.0.
@misc{iil_note_y7hb29k8,
author = {{iinventedlight}},
title = {{Docker commit: create an image from a container}},
howpublished = {iinventedlight Library},
year = {2026},
date = {2026-11-18},
url = {https://iinventedlight.com/library/notes/docker-commit/},
note = {Permanent ID iil:note:y7hb29k8. 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-commit.md.