What are Git and GitHub?
Git is a version control system: it records every change to your files, so you can go back in time, work on several things at once and combine work from many people. GitHub is a website that hosts Git repositories and adds collaboration tools like pull requests, issues and automation.
Almost every software team uses Git, and most use GitHub or a similar service such as GitLab. Writers, designers and data analysts use it too. It is one of the few skills every developer job description takes for granted.
How to use this Git and GitHub roadmap
Use the command line, not only a GUI. Buttons hide what Git is doing, and the terminal makes the concepts click.
Practise on a throwaway repository. Break things on purpose, then fix them. That is the fastest way to stop being afraid of Git.
1Step 1: Git basics
Install Git and make your first commits.
What is it?
This step covers what version control is, setting up Git and the everyday cycle of changing files, staging and committing.
What to learn
Commit small and often, with messages that say why you made the change.
Learn each topic here
What version control is
A history of your project that lets you undo changes, compare versions and work safely.
Installing and configuring Git
Installing Git and setting your name and email with git config.
Repositories
A folder Git tracks, created with git init or copied with git clone.
Staging and committing
git add chooses changes; git commit saves them as a snapshot with a message.
Why it matters: This two-step process is the heart of Git.
Status, log and diff
Seeing what changed, what is staged and the history of commits.
Example
bash
git init my-project
cd my-project
echo "# My Project" > README.md
git add README.md
git commit -m "Add README"
git log --onelineCreates a repository, adds a file and makes the first commit.
Helpful resource: Pro Git book (free)
2Step 2: Branching and merging
Work on many things at once.
What is it?
Branches let you build features or fix bugs without breaking the main code. Merging brings that work back together.
What to learn
Create a new branch for every feature or fix, however small.
Learn each topic here
Branches
Independent lines of work created with git branch or git switch -c.
Switching branches
Moving between branches with git switch, and what happens to your files.
Merging
Combining branches with git merge, including fast-forward and merge commits.
Merge conflicts
When two branches change the same lines, and how to resolve them calmly.
Why it matters: Everyone hits conflicts; resolving them is a core skill.
Rebasing basics
Replaying commits on top of another branch for a cleaner history.
Example
bash
git switch -c feature/login
# ...edit files...
git commit -am "Add login form"
git switch main
git merge feature/loginCreates a feature branch, commits work and merges it back into main.
Helpful resource: Learn Git Branching (interactive)
3Step 3: GitHub and remotes
Share your code and work with others.
What is it?
Remotes connect your local repository to one on GitHub. This step covers pushing, pulling, cloning and the GitHub features you’ll use daily.
What to learn
Set up SSH keys early. It saves typing credentials and avoids authentication headaches.
Learn each topic here
Remotes
Links to repositories on GitHub, usually called origin.
Push, pull and fetch
Sending your commits up and bringing others’ commits down.
Cloning and forking
Copying a repository to your computer, or making your own copy of someone else’s on GitHub.
SSH keys and authentication
Securely connecting to GitHub without passwords.
README and .gitignore
Explaining your project and keeping secrets, builds and junk files out of Git.
Why it matters: A good README makes your project look professional.
Example
bash
git remote add origin git@github.com:you/my-project.git
git push -u origin main
git pullConnects to a GitHub repository, pushes main and later pulls new changes.
Helpful resource: GitHub Docs: Get started
4Step 4: Pull requests and collaboration
How teams actually work together.
What is it?
Pull requests are where code gets reviewed, discussed and merged. This step covers PRs, code review and the most common team workflows.
What to learn
Keep pull requests small. Reviewers give better feedback on 200 lines than on 2,000.
Learn each topic here
Pull requests
Proposing changes from a branch, with a description, discussion and review.
Code review
Commenting, requesting changes and approving, kindly and specifically.
Issues and project boards
Tracking bugs and tasks and linking them to pull requests.
Branching workflows
GitHub Flow, trunk-based development and Git Flow, and when teams use each.
Contributing to open source
Forking, following contribution guides and opening your first PR to a real project.
Why it matters: A merged open-source PR is great on a CV.
Example
markdown
## What
Adds password reset by email.
## Why
Users can't recover accounts today (#42).
## How to test
1. Click "Forgot password"
2. Check email and follow linkA clear pull request description reviewers will thank you for.
Helpful resource: First Contributions
5Step 5: Fixing mistakes and advanced Git
Undo almost anything.
What is it?
Everyone makes Git mistakes. This step teaches you how to undo, rewrite and recover work safely.
What to learn
git reflog can recover almost anything you think you’ve lost. Learn it before you need it.
Learn each topic here
Undoing changes
git restore, git reset and git revert, and when each is safe to use.
Why it matters: Knowing revert vs reset prevents damaging shared history.
Amending and interactive rebase
Fixing the last commit or tidying several commits before sharing.
Stash
Putting unfinished work aside to switch tasks quickly.
Reflog
Git’s record of where your branches have been, used to recover lost commits.
Tags and releases
Marking versions like v1.0.0 and publishing releases on GitHub.
Example
bash
git commit --amend -m "Fix typo in login message"
git revert a1b2c3d # undo a shared commit safely
git stash && git switch hotfix
git reflog # find lost commitsA few everyday commands for fixing mistakes.
Helpful resource: Oh Shit, Git!?!
6Step 6: GitHub Actions and your profile
Automate work and stand out.
What is it?
GitHub Actions runs tasks automatically, such as tests on every pull request. Your GitHub profile also acts as a public portfolio.
What to learn
Pin your six best repositories and write a short profile README about what you build.
Learn each topic here
GitHub Actions basics
Workflows, jobs and steps defined in YAML files.
CI for tests and linting
Running tests and code checks automatically on every push or pull request.
Secrets and environments
Storing API keys safely for workflows and deployments.
GitHub Pages
Hosting a free website or portfolio directly from a repository.
Profile and portfolio
Pinned repos, a profile README and consistent commit history that shows real work.
Why it matters: Recruiters really do look at GitHub profiles.
Example
yaml
name: tests
on: [push, pull_request]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with: { node-version: 20 }
- run: npm ci && npm testA workflow that runs tests on every push and pull request.
Helpful resource: GitHub Actions documentation
Git and GitHub roadmap project ideas
Git skills show up in how your projects look on GitHub. Clean history, clear READMEs and working CI all signal that you can work on a team.
Personal project history
A small project with 20+ clear, meaningful commits.
Profile README
A GitHub profile page that introduces you and your work.
Team simulation
Two accounts or a friend, branches, PRs, reviews and conflicts.
Open-source contribution
A merged pull request to a real project.
CI/CD pipeline
Tests, linting and deployment with GitHub Actions.
Release workflow
Tags, changelog and GitHub Releases for versioned software.
Tips to finish this Git and GitHub roadmap
- Use the terminal. It shows exactly what Git is doing and works the same everywhere.
- Never commit secrets. Keep passwords and API keys in environment variables and .gitignore.
- Pull before you push. Staying up to date with main avoids most painful conflicts.
- Don’t panic. Almost every Git mistake can be undone. Stop, read the message, then fix it.
Career paths and next steps
Git is a foundation for every developer path. Continue with the Frontend, Backend or Full Stack Developer roadmap.
If automation interests you, the DevOps Engineer roadmap builds on Git and GitHub Actions.
Related roadmaps
Git and GitHub Roadmap FAQs
What is the difference between Git and GitHub?
Git is the version control tool that runs on your computer. GitHub is an online service that hosts Git repositories and adds collaboration features.
How long does it take to learn Git?
You can learn the everyday commands in a week. Being comfortable with branching, conflicts and recovery takes a few weeks of real use.
Is GitHub free?
Yes. Free accounts include unlimited public and private repositories and a monthly allowance of GitHub Actions minutes.
Should I learn Git commands or use a GUI?
Learn the commands first so you understand what is happening. A GUI is fine later for convenience.