Git: Delete Tags From Both Local and Remote Repositories

Tyler Tyler (291)
Total time: 2 minutes 

Cleaning up unused tags is an important part of Git housekeeping. This guide will show you how to delete tags from both local and remote Git repositories.


git push --delete origin <tag_name>
git tag -d <tag_name>

Continue reading to see a breakdown of each command.

Posted in these interests:
h/git15 guides
h/code68 guides

As of Git 1.7.0 you can use git push --delete to delete a remote branch or tag.

git push --delete <remote_name> <tag_name>

In most cases, the remote name is origin, so you'll use:

git push --delete origin <tag_name>

Deleting a tag from your local repository is easy:

git tag -d <tag_name>

So, git tag -a <tag_name> adds a tag, and git tag -d <tag_name> deletes a tag.