docker runIT technician command center
Containers · Docker and Kubernetes

docker run

Create and run a container.

Copy-ready commanddocker run
docker run -d --name web01 -p 8080:80 nginx:latest

Requirements and permissions

Requirements
Docker Engine, Docker Compose, or kubectl
Permissions
Container or cluster permissions vary
Last reviewed
2026-07-31

Examples

Basic example

Create and run a container.

docker run -d --name web01 -p 8080:80 nginx:latest

Common errors

Command not found

Confirm Docker Engine, Docker Compose, or kubectl is installed and available in your current shell.