---
source: https://iinventedlight.com/library/notes/docker-start-containers-automatically.md
title: "Docker restart policies: start containers automatically"
license: CC-BY-4.0
license_url: https://creativecommons.org/licenses/by/4.0/
source_license: "Apache License 2.0 (Docker, Inc.); Apache License 2.0 (Docker, Inc.); prose restates cited source lines in own words"
license_family: mixed-green
attribution: "Summary by iinventedlight (AI-assisted). Sources: Docker, Inc., Start containers automatically; Docker, Inc., Start containers automatically (source). Apache-2.0 (https://raw.githubusercontent.com/docker/docs/main/LICENSE). Copyright Docker, Inc."
author: "iinventedlight (synthesis of cited sources); text drafted with AI assistance"
date: 2026-11-26
status: published
approved_by: "Cole Withington, 2026-11-27 14:30 PT: \"Yes, publish all of that now\""
checked_on: 2026-11-26
as_of: 2026-11-26
confidence: medium
untested: "Not reproduced (2026-11-26). Official docs and source files were read; no test suite, server, or API call was run for this note."
category: coding-references
topic_area: "code-devops: docker-start-containers-automatically"
tags: [docker, restart, containers, daemon, policies]
client: Librarian
sources:
  - id: S1
    title: "Start containers automatically"
    publisher: Docker, Inc.
    url: https://docs.docker.com/engine/containers/start-containers-automatically/
    accessed: 2026-11-26
    license: "Apache License 2.0"
  - id: S2
    title: "Start containers automatically (source)"
    publisher: Docker, Inc.
    url: https://raw.githubusercontent.com/docker/docs/main/content/manuals/engine/containers/start-containers-automatically.md
    accessed: 2026-11-26
    license: "Apache License 2.0"
---
# Docker restart policies: start containers automatically
**Answer:** Docker restart policies control whether containers start automatically.

## How they differ from live restore

The policies apply when containers exit, or when Docker restarts.

Docker recommends restart policies, and warns against using process managers to start containers.

The live-restore flag on the dockerd command is a different mechanism.

During a Docker upgrade, that flag can keep containers running.

## Policy values

The no policy is the default and does not automatically restart the container.

The on-failure policy restarts a container that exits with a non-zero exit code.

The always policy restarts the container if it stops.

The unless-stopped policy is similar to always, except a stopped container is not restarted after the daemon restarts.

## See also

- [docker-restart-policies](https://iinventedlight.com/library/notes/docker-restart-policies/)
- [docker-live-restore](https://iinventedlight.com/library/notes/docker-live-restore/)
- [docker-start](https://iinventedlight.com/library/notes/docker-start/)

## Claims

- id: C1
  claim: Restart policies control automatic container starts.
  source: S1
  evidence: "to control whether your containers start automatically"

- id: C2
  claim: Docker recommends restart policies instead of process managers.
  source: S1
  evidence: "avoid using process managers to start containers"

- id: C3
  claim: Restart policies control automatic container starts.
  source: S2
  evidence: "to control whether your containers start automatically"

- id: C4
  claim: Restart policies differ from the live-restore flag.
  source: S2
  evidence: "Restart policies are different from the `--live-restore` flag"

## Sources

- [S1] Start containers automatically. Docker, Inc.. https://docs.docker.com/engine/containers/start-containers-automatically/ . License: Apache License 2.0. Accessed 2026-11-26.

- [S2] Start containers automatically (source). Docker, Inc.. https://raw.githubusercontent.com/docker/docs/main/content/manuals/engine/containers/start-containers-automatically.md . License: Apache License 2.0. Accessed 2026-11-26.

License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources: Docker, Inc., Start containers automatically; Docker, Inc., Start containers automatically (source). Apache-2.0 (https://raw.githubusercontent.com/docker/docs/main/LICENSE). Copyright Docker, Inc. Text was condensed and changed from the originals.

---

Agents: [/agents.md](/agents.md) | [/.well-known/agent-library.json](/.well-known/agent-library.json).
