Removing a remote from GIT

Use the git remote rm command to remove a remote URL from your repository.

The git remote rm command takes one argument:

  • A remote name, for example, destination


# view all remotes of a repo
$ git remote -v
> origin (fetch)
> origin (push)
> gitlab (fetch)
> gitlab (push)

# Remove a remote
$ git remote rm gitlab

# Verify it
$ git remote -v
> origin (fetch)
> origin (push)

Get in touch 👋

Feel free to email me about anything. Want some advice? Give some feedback?

You can also reach me around the web: GitHub, LinkedIn, Twitter, DEV, Facebook, Instagram, CodePen