Skip to content
Latchkey

What Is CI_COMMIT_REF_NAME?

CI_COMMIT_REF_NAME is the branch or tag name that the pipeline is building.

CI_COMMIT_REF_NAME gives you the human-friendly ref name for conditionals, environment naming, and slugged URLs.

Note

For a value safe in URLs and Kubernetes names, use CI_COMMIT_REF_SLUG, which lowercases and sanitizes the name.

Key takeaways

  • CI_COMMIT_REF_NAME is the branch/tag name.
  • CI_COMMIT_REF_SLUG is the URL-safe form.
  • Useful for rules and naming.

Related guides

Tired of flaky CI? Latchkey auto-heals failed jobs and retries them for you. Start free →