Ad space (banner)
AD

Got the fundamentals? A structured Docker course is a fast way to level up.

Find Docker courses on Udemy

Affiliate link. Costs you nothing extra.

🐳Docker Lessons
Lesson 5 / 45

Fetching an Image with docker pull

When you want to bring an image onto your machine, use docker pull. It downloads an image from a registry such as Docker Hub.

The syntax is docker pull image[:tag]. Omit the tag and you get latest.

Running docker pull nginx downloads the official nginx image layer by layer, finishing with Status: Downloaded newer image for nginx:latest.

A common stumble is relying on latest in production. The image behind that tag changes over time, so the same command can produce different results months apart — pin an explicit version instead.

In real work, pulling the images your project depends on is the first step of setting up any environment.

Docker
Try it (type this into the pseudo terminal)
docker pull nginx

🧑‍💻 You can type this command into the Docker pseudo terminal to try it yourself (this page itself has no interactive terminal).

Ad space (banner)
Ad space (in-article)