How to get the remote repository url in git?

If you have already added a remote repository to your local repository or cloned your local repository from a remote repository, you can use git remote -v to get the remote repository URL.

Example:

Clone a git remote repository:

Note: If you already have a local repository, you can also add a remote repository using git remote add origin <remote_repository_url>

Get into your cloned repository:

Get the remote repository URL:

Leave a Reply