Skip to content
Latchkey

Docker "client version too new for server API" in CI

The Docker CLI and daemon speak a versioned API. When the CLI is newer than the daemon and pins an API version the daemon predates, the daemon refuses with "client version is too new". This is a config/compatibility mismatch, common when a fresh CLI talks to an older remote daemon.

What this error means

Any docker command fails with Error response from daemon: client version 1.45 is too new. Maximum supported API version is 1.41.

docker
Error response from daemon: client version 1.45 is too new. Maximum supported API version is 1.41

Common causes

A newer CLI against an older daemon

The runner upgraded the CLI but the remote/dind daemon is on an older release.

A pinned DOCKER_API_VERSION too high

An explicit DOCKER_API_VERSION set above what the daemon supports forces the mismatch.

How to fix it

Pin the API version to the daemon maximum

  1. Set DOCKER_API_VERSION to the version the error reports as the daemon maximum.
  2. The CLI will then negotiate down to a compatible version.
Terminal
export DOCKER_API_VERSION=1.41
docker version

Align CLI and daemon versions

  1. Upgrade the daemon (or the dind service image) to match the CLI.
  2. Or downgrade the CLI to one the daemon supports.
service config
services:
  docker:
    image: docker:27-dind

How to prevent it

  • Keep CLI and daemon on matching major versions in CI.
  • When unavoidable, pin DOCKER_API_VERSION to the daemon maximum.

Frequently asked questions

What causes ""client version too new""?
The runner upgraded the CLI but the remote/dind daemon is on an older release.
How do I fix "client version too new"?
Pin the API version to the daemon maximum

Related guides

References

Latchkey auto-heals failures like this one - detected, fixed, and retried without you. Start free → 30-day trial · No credit card