← Back to Blog
Engineeringless than a minute read

Git: What It Is and Why Developers Use It

An introduction to Git as a distributed version control system, with a small example of tracking and sharing changes.

By Esra Durmaz

  • Git
  • Version Control
  • Software Engineering
  • Command Line

Git is a version control system for recording and managing changes to files. It is widely used in software development because it helps developers understand how a project changed, return to earlier versions, and work on changes without overwriting one another.

Git is distributed

A Git repository contains the project's history, not only the latest copy of its files. When a repository is cloned, the local copy contains the history needed for many operations. This means developers can inspect changes and create commits without being continuously connected to a remote host.

Git is separate from services such as GitHub or GitLab. Git manages version history; those services host repositories and provide collaboration features such as pull requests and issue tracking.

Commits and branches

A commit records a set of staged changes with a message. A branch is a movable name for a line of development. A developer can create a branch to work on a change independently, then merge it into another branch when it is ready.

A small local workflow might look like this:

git init git status git add README.md git commit -m "Add project notes" git switch -c update-docs

git add selects changes for the next commit. git status shows the current working-tree state, and git commit records the staged snapshot. A branch does not automatically share work with anyone else; sharing usually involves a remote repository.

Working with a remote

A remote is a named reference to another repository, commonly hosted on a platform such as GitHub or GitLab. After committing locally, a developer can push commits to the remote. To incorporate work already pushed by others, they can fetch or pull updates and then resolve any conflicts if changes overlap.

This separation between local history and remote hosting makes it possible to work offline, while still supporting collaboration when the repository is shared.

Why it is useful

Version history provides context for reviewing a change and makes it easier to compare versions or restore earlier work. Branches provide a practical place to isolate changes. Together, these features support collaboration, but they do not replace communication or careful review.

What I learned

The key distinction for me is that Git records project history, while a hosting service makes a repository easier to share with a team. Learning the basic cycle of checking status, staging, committing, and using branches gives a clear foundation for understanding collaborative development workflows.