Error Knowledge Base Docker invalid_reference_lowercase

invalid reference format: repository name must be lowercase

Docker rejected the image reference because repository names must be lowercase, so uppercase letters or malformed syntax made it invalid.

What Is Wrong With the Image Reference

Docker rejected the image reference because repository names must be lowercase, so uppercase letters or malformed syntax made it invalid.

Docker rejected the image reference locally before it tried to contact a registry. This is about the name you passed, not registry availability.

Fix the image reference syntax

Print the final image reference string before running Docker so you can see the exact mixed-case value.

Convert the repository path to lowercase (for example MyOrg/API:latest -> myorg/api:latest).

If a script builds the reference from variables, normalize those variables before concatenating them.

Retry the original docker pull, docker run, or docker build -t command with the lowercase reference.

Why Docker Rejected the Reference

Usually this comes down to one or more repository path segments contain uppercase letters, an environment variable expanded into a mixed-case image name at runtime, or the command copied an image reference from documentation or CI variables without normalizing it.

Re-run the Corrected Image Reference

Run the corrected command and confirm Docker accepts the image reference.

If the value comes from CI variables, print the resolved value in CI and confirm it is lowercase there too.

Check the exact image reference you passed

Echo the final reference string from the shell or CI logs.

Check each repository segment for uppercase letters before the optional :tag or @sha256:... suffix.

Examples

Invalid: MyOrg/API:latest
Invalid: ghcr.io/Acme/backend:1.4.2
Valid: myorg/api:latest
Valid: ghcr.io/acme/backend:1.4.2

How Docker validates the command before it runs

Docker parses image references locally before it makes any registry request. Repository names are restricted to lowercase syntax, so mixed-case references fail immediately.

Prevent It From Coming Back

To prevent this, keep registry namespaces and repository names lowercase across repos, env vars, and CI templates, and validate generated image references in scripts before calling Docker.

Need help or found a mistake? Contact RepoFlow support for questions.

Join our mailing list