How to list tags in Git

Listing Git tags is essential for version management, release tracking, and understanding the release history of your project. With over 25 years of experience in software development and as the creator of CoreUI, I use Git tags extensively for managing releases across all our open-source projects. The most straightforward approach is using the git tag command which displays all tags in alphabetical order. This provides quick access to version information and helps coordinate releases across development teams.

Use git tag command to list all tags in your repository, with optional filters for specific patterns.

# List all tags
git tag

# List tags matching a pattern
git tag -l "v1.*"

# List tags with annotation messages
git tag -n

# List latest 10 tags
git tag --sort=-version:refname | head -10

The basic git tag command shows all tags alphabetically, while git tag -l "pattern" filters tags using glob patterns. The -n option displays tag names along with their annotation messages, and --sort=-version:refname sorts tags by version number in descending order. You can pipe the output to head or tail to limit the number of results displayed.

Best Practice Note:

This is the same workflow we use in CoreUI repositories to track releases and coordinate versioning across multiple packages. Use semantic versioning patterns like “v1.*” to easily filter major releases and maintain consistent release management.


Speed up your responsive apps and websites with fully-featured, ready-to-use open-source admin panel templates—free to use and built for efficiency.


About the Author

Subscribe to our newsletter
Get early information about new products, product updates and blog posts.

Answers by CoreUI Core Team