Git Clone vs Fork in GITHUB

This is basically an article for Git/Github NEWBIES

Let’s start by explaining each one at a time :

is simply the process of downloading a GitHub project from an online repository to your local machine using Git.

When you fork a repository, you create a copy of the original repository (upstream repository) but the repository is copied to your GitHub account, not on your local machine.

Forking is a concept while cloning is a process. Forking is just containing a separate copy of the repository and there is no command involved. Cloning is done through the command ‘git clone‘ and it is a process of receiving all the code files to the local machine.


Let’s say you want to contribute to an open-source project;

Now you can apply any changes or edits you which to on the local copy on your machine, once you finished your edits you commit them and push them to your Github repo.

Your Github repo now is synced with the changes made to your local machine’s copy, it’s time to merge those changes with the original “open-source project repo”.

Changes made to the forked repository can be merged with the original repository via pull request. A Pull request knocks on the repository owner and tells them “Please check my changes and merge them if you like it

If they accept, the original repo will have your changes in it, and Congrats you just contributed to an Open-source project

Connect with me on Linkedin for more interesting tech stuff!

Thank you very much for your attention

Backend Developer in Pursuit of Happiness | Entrepreneur in the making

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store