# Container Image

> The saved pack that a container starts from. One image can start many of them.

**Field:** Infrastructure  
**Category:** Containers  
**Also known as:** Docker Image, OCI Image, Image (Containers)

## Think of it like

It is like a cookie cutter. One cutter makes as many cookies as you want, all the same.

## Definition

A container image is the saved package a container starts from. It holds the app, its tools and its settings, stacked in layers. Each layer adds or changes some files. An image never changes once it is built. To change it, you build a new one with a new tag. One image can start many containers at the same time.

## Example

Emma builds an image of her shop app and tags it 1.4. The test server and the live server both start containers from that same image.

## Example code

```bash
docker build -t shop-app:1.4 .
docker run -d shop-app:1.4
```

The first line builds the image and names it. The second starts a container from it.

## Why it matters

The image never changes, so what you tested is exactly what goes live.

## Common mistake

Treating an image and a container as the same thing. The image is the plan, and a container is one copy running from it.

## Three principles

- **Built in layers.** Each layer adds or changes some files.
- **Never changes.** A change means a new image.
- **Tagged by version.** The tag says which build it is.

## Related terms

- [Container](https://learn.benibix.com/term/infrastructure/container)
- [Dockerfile](https://learn.benibix.com/term/infrastructure/dockerfile)
- [Container Registry](https://learn.benibix.com/term/infrastructure/container-registry)
- [Docker Hub](https://learn.benibix.com/term/infrastructure/docker-hub)
- [Machine Image](https://learn.benibix.com/term/infrastructure/machine-image)
- [Build Artifact](https://learn.benibix.com/term/development/build-artifact)
- [Image Tag](https://learn.benibix.com/term/infrastructure/image-tag)

## Told apart from

- [Container Image vs Container](https://learn.benibix.com/compare/container-image-vs-container): People use image and container as if they meant the same thing, and they do not. An image is the saved package, and it never changes. A container is one copy of it that is running right now. One image can start many containers. Delete a container, and the image is still there to start a new one.
- [Machine Image vs Container Image](https://learn.benibix.com/compare/machine-image-vs-container-image): People think a machine image and a container image are the same kind of file, and they are not. A machine image is a whole saved disk, with its own system. A virtual machine starts from it. A container image holds just an app and its parts. It borrows the system of the machine that runs it. So a machine image is far bigger and slower to start.

![A row of steps from left to right. A Dockerfile is built into an image. The image is pushed up to a registry. A server pulls the image down from the registry and runs it as two containers.](https://learn.benibix.com/diagrams/inf-image-flow.svg)

---

Source: https://learn.benibix.com/term/infrastructure/container-image
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-17
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
