Skip to content

Docker Installation

This guide helps you install Docker on Mac, Linux, and Windows, and also provides a link to try Docker online via Play with Docker.


Docker on Mac

Docker Desktop is the easiest way to install Docker on macOS. It includes both a GUI and CLI tools.

Installation Steps:

  1. Download Docker Desktop from the official site: Docker Desktop for Mac
  2. Open the downloaded .dmg file and drag Docker to the Applications folder.
  3. Launch Docker from Applications.
  4. Follow the onboarding instructions to finish the setup.
  5. Verify installation by opening Terminal and running:
docker --version
docker compose version
docker run hello-world

Optional: Install via Homebrew CLI (Not Recommended):

If you prefer a CLI-only installation:

brew install docker docker-compose

Docker on Linux

For Linux, it is recommended to follow the official installation instructions for your distribution to ensure you get the latest version.

Ubuntu / Debian

Visit the official Docker guide: Docker Desktop for Ubuntu

Fedora / CentOS

Visit the official Docker guide: Docker Desktop for Fedora

After Installation

After installation, you may want to run Docker without sudo:

sudo usermod -aG docker $USER
newgrp docker

Verify installation by opening Terminal and running:

docker --version
docker compose version
docker run hello-world

Docker on Windows

Docker Desktop is available for Windows 10/11 and includes both GUI and CLI tools.

  1. Download Docker Desktop from: Docker Desktop for Windows
  2. Run the installer and follow the setup instructions.
  3. Verify installation in PowerShell or CMD:
docker --version
docker compose version
docker run hello-world

Play with Docker

If you want to try Docker without installing it locally:


References