How To Delete a Git Tag

It's easy to delete a git tag from your local and remote repositories.

Let's say you created tag v1.0 too early. You can delete it from your local repository by running the following command.

$ git tag -d v1.0

If you've already pushed the tag, you can remove it from your remote repository with this command.

$ git push origin :refs/tags/v1.0

Then, if you want to create it and push it again later, you can go right ahead and do so.

$ git tag -a v1.0 -m "My new tag"
$ git push origin --tags

Let's Connect

Keep Reading

Safely Force Pushing in Git

If force-pushing is part of your git workflow, here's a tip that can help you avoid disaster.

Jul 22, 2021

Git Merge: Accept All Changes

Have you encountered a large merge when you know you are going to accept all current or incoming changes? There's a way to achieve without stepping through each file.

Sep 17, 2020

Backup Your Code and Develop Cross-Platform Using Git

I recently discovered Git and it changed everything.

Feb 04, 2013