git push origin -d <branchname>

Delete a remote branch

This command sends a request to the remote repository to delete a specified branch.

The -d flag stands for --delete. It tells the git push command to remove the reference from the remote repository. After the deletion, other users can no longer see or pull from the branch. Remember to replace <branchname> with the actual name of the branch you want to delete.

The longer version of -d flag is --delete.

Sign in to enable bookmarking, reminders, progress-tracking and more...