Install Docker

Install Docker Desktop on Windows/macOS or Docker Engine on Linux, then verify it works with a test container.

Choosing what to install

PlatformInstall
Windows / macOSDocker Desktop (GUI + engine + Compose)
LinuxDocker Engine (CLI/daemon) or Docker Desktop

Verify the install

bash
docker --version        # e.g. Docker version 27.x
docker run hello-world  # pulls a tiny image and runs it

hello-world downloads a minimal image and runs it, confirming the daemon is running and can pull and execute containers.

How Docker runs

The docker CLI talks to a background daemon (dockerd) that does the real work β€” building images, running containers, managing networks and volumes. Docker Desktop bundles and starts this for you.

docker vs docker compose

  • docker ... β€” manage a single image or container.
  • docker compose ... β€” run multiple containers from a YAML file (its own chapter).
Note: Modern Docker uses docker compose (a built-in subcommand). The old standalone docker-compose (with a hyphen) is legacy β€” prefer the space form.
Tip: If docker run hello-world succeeds, your setup is complete. On Linux, you may need to add your user to the docker group (or use sudo) so you can run Docker without root each time.
Free preview. Sign in and subscribe to unlock all 809 lessons across 25 courses.
Install Docker β€” Docker | Full Stack Learning Simplified