GitHub: Clone (Download) a Remote Repository

Free Git Tutorial

Learn how to contribute to a Git repo that's already been created, clone a Git repo using Visual Studio Code, and give someone access to your private GitHub repo with these easy-to-follow steps.

This exercise is excerpted from Noble Desktop’s Git & GitHub training materials and is compatible with updates through 2022. To continue learning web development with hands-on training, check out our coding bootcamps in NYC and live online.

Contributing to Someone Else’s Repo

When you want to start contributing to a Git repo that has already been created, you can clone it (download a copy) from GitHub. If it’s a private repo, they need to invite you.

Clone a Git Repo

  1. First you’ll need the URL of the Git repo. When viewing the repo on GitHub, click the Code button to see the URL. Copy that URL by clicking the button to its right.
  2. In Visual Studio Code choose File > New Window.
  3. Open the Source Control panel vscode soure control icon on the left of the window.
  4. In the Source Control panel vscode soure control icon click Clone Repository.
  5. In the panel that appears at the top the window, paste the URL (or git clone command) and hit Return (Mac) or Enter (Windows).
  6. You’ll be asked where you want to store the repo.

    Navigate to the folder where you want to store the repo (a new folder for the repo will be created here) and click Select Repository Location.

  7. If you’re asked Would you like to open the cloned repository? (at the bottom right of the VS Code window) click Open.

Giving Someone Access to Your Private GitHub Repo

If you have a private GitHub repo that you want someone else to contribute to:

Full-Stack Web Development Certificate: Live & Hands-on, In NYC or Online, 0% Financing, 1-on-1 Mentoring, Free Retake, Job Prep. Named a Top Bootcamp by Forbes, Fortune, & Time Out. Noble Desktop. Learn More.
  1. On github.com go to the page for your repo.
  2. Click the Settings tab.
  3. In the left sidebar, click Manage access.
  4. Click Invite a collaborator.
  5. Enter the person’s email address and follow any remaining prompts.
photo of Dan Rodney

Dan Rodney

Dan Rodney has been a designer and web developer for over 20 years. He creates coursework for Noble Desktop and teaches classes. In his spare time Dan also writes scripts for InDesign (Make Book JacketProper Fraction Pro, and more). Dan teaches just about anything web, video, or print related: HTML, CSS, JavaScript, Figma, Adobe XD, After Effects, Premiere Pro, Photoshop, Illustrator, InDesign, and more.

More articles by Dan Rodney

How to Learn Git

Master Git with hands-on training. Git is a free, open-source version control system that allows developers to track the changes they make to code.

Yelp Facebook LinkedIn YouTube Twitter Instagram