This write-up will provide the procedure for cloning the GitHub repository on Windows.
How to Clone GitHub Repository on Windows?
To clone the GitHub repository on Windows, try out the below-given instructions:
- Sign into your GitHub account.
- Select a GitHub repository and copy its HTTPS URL.
- Start the “Command Prompt” by using the Startup menu.
- Go to the Git local repository.
- Execute the “git clone” command to clone the GitHub repository.
- Navigate to the cloned repository for verification.
Step 1: Sign in to GitHub
First, Sign in to your GitHub account by providing the required information and hit the “Sign in” button to move ahead:
Step 2: Choose a Repository
Click on the user profile picture, and select the “Your repositories” option from the appeared drop-down menu:
Next, select your preferred GitHub repository. For instance, we have chosen the “testrepo” repository:
Step 3: Copy the HTTPS URL
After that, click on the “Code” button and copy the “HTTPS” URL to the clipboard:
Step 4: Launch Command Prompt
Open the “Command Prompt” with the help of the Startup menu on Windows:
Step 5: Redirect to Git Local Directory
Run the “cd” command and navigate to the stated Git local repository:
Step 6: Clone GitHub Repository
To clone the GitHub repository, use the “git clone” command and paste the copied GitHub repository “HTTPS” URL:
The below-provided image indicates that the GitHub repository has been successfully cloned on Windows:
Step 7: Navigate to Cloned Repository
Verify whether the GitHub repository has been cloned on the local repository or not, using the provided command:
It can be observed that we have successfully navigated to it:
That’s all about cloning the GitHub repository on Windows.
Conclusion
To clone the GitHub repository on Windows, first, sign in to your GitHub account, and select and copy the “HTTPS” URL of the desired GitHub repository. Next, open the “Command Prompt” and redirect to the local Git repository using the “cd” command. After that, execute the “git clone” command and clone the GitHub repository. Lastly, move to the cloned repository for verification. This post has stated the method for cloning the GitHub repository on Windows.