How to Compare Two Branches in Github
- George Apostolov
- 05 Sep 2025
Guide
Navigate to the repository where the branches are located.
Click on the 'Compare & pull request' button.
Click the branch dropdowns to change the base and compare branches.
The 'base' branch is the branch you want to compare to.
The 'compare' branch is the branch you want to compare from.
GitHub will show you a comparison of commits and changes or file differences between the two branches.
Create your first interactive demo in minutes
No credit card required • Start building today


