There could be some situation when you tagged your code in local Git repository and pushed it to remote and later you decided to delete the tag. This is simple to delete the tag reference from local, but how to perform the same in remote?

 

Today we are going to see the bash command(s) by which you will be able to remove the tag information from Git. Let's see, how!

 

How to delete a tag from Git remote repository? (www.kunal-chowdhury.com)

 

Tag assigns a meaningful name with a specific version in the repository. Tags are very similar to branches, but the difference is that tags are immutable. You can create a tag on a commit by using the '$ git tag' command. Usually, developers create tags for product releases.

 

To delete a local tag, enter either of the following commands in Git Bash:

$ git tag --delete tagName

$ git tag -d tagName

 

To delete a remote tag, enter either of the following commands in Git Bash:

$ git push origin :tagName

$ git push --delete origin tagName

 

That's all. I hope you liked the tips shared above. In case, you missed my other posts on 'Git Tutorial', do visit at http://git.kunal-chowdhury.com. Don't forget to share the posts in your social channel. Click the social sharing buttons and share your love.

 

 

 


Kunal Chowdhury

About the Author

Solution Architect & Former Microsoft MVP

Kunal Chowdhury is an enterprise solution architect and former multi-year Microsoft MVP. He is the author of three technical books: Windows Presentation Foundation Development Cookbook, Mastering Visual Studio 2017, and the Mastering Visual Studio 2019.

He publishes technical and non-technical articles on .