Docker Tag Generator

Versioned Docker image tags for CI pipelines

Ad placeholder (leaderboard)

Build tags your registry will accept

The Docker Tag Generator produces image tag strings that follow Docker’s tag grammar and common CI conventions. Pick a style — semantic version, short git hash, the two combined, or a timestamp — add an optional environment suffix, and get tags you can drop straight into a docker build -t command or a pipeline script.

How it works

Docker restricts a tag to letters, digits, underscores, periods and hyphens, with a 128-character limit and no leading period or hyphen. The generator builds each tag from those characters only. A semver core is MAJOR.MINOR.PATCH; a git-style identifier is a seven-character lowercase hex string mimicking an abbreviated commit SHA; a timestamp is a sortable YYYYMMDD-HHMM stamp.

The combined version-sha style joins a release with its source commit (for example 1.4.0-a1b2c3d) so the tag is both readable and immutable. An optional environment suffix such as -staging records the build target. Because mutable tags like latest defeat reproducible deploys, the tool deliberately produces immutable, content-anchored tags instead.

Tips and example

  • For release builds use the version or version-sha style: 2.0.1 or 2.0.1-9f3c0de.
  • For per-commit CI builds use the git-sha style so each push gets a unique, immutable tag.
  • For nightly builds use the timestamp style: 20260606-0300.
  • Keep tags lowercase by convention even though uppercase is technically allowed — many tools and humans expect it.
  • All hashes and stamps are synthetic; never treat a generated tag as a real build artifact.
Ad placeholder (rectangle)