
Git's built-in diff output works, but reading a long change as a wall of plus and minus signs gets tiring. Pointing Git at Beyond Compare gives you a side-by-side view with in-line highlights, editable panes and a proper three-way merge window. Git already knows about Beyond Compare, so the setup takes only a few commands. This guide covers every platform and the extra options that make the combination shine.
What You Need First
- Beyond Compare 5 installed and opened at least once.
- Git installed and available in your terminal.
- For three-way merges, the Pro edition or an active trial. Standard handles diffs fine but not three-way merges.
Git recognizes the short tool name bc and knows how to call Beyond Compare with the right arguments. You mainly need to tell Git where the program lives, if it cannot find it on its own.
Setup on Windows
Open Git Bash, PowerShell or Command Prompt and run:
git config --global diff.tool bc
git config --global difftool.bc.path "C:/Program Files/Beyond Compare 5/bcomp.exe"
git config --global merge.tool bc
git config --global mergetool.bc.path "C:/Program Files/Beyond Compare 5/bcomp.exe"
Use forward slashes in the path, as shown. If you installed Beyond Compare for your account only, the program sits inside your user profile instead, so adjust the path to match. The bcomp.exe helper is the right file to point at, because it waits for you to close the comparison before handing control back to Git.
Setup on macOS
First, open Beyond Compare and choose Install Command Line Tools from the Beyond Compare menu. This places bcomp on your path. Then run:
git config --global diff.tool bc
git config --global merge.tool bc
Because bcomp is already on the path, no extra path setting is needed.
Setup on Linux
The Linux packages install bcompare and its helper automatically. Run the same two commands:
git config --global diff.tool bc
git config --global merge.tool bc
Useful Extra Settings
These optional settings remove small annoyances:
| Command | What it does |
|---|---|
git config --global difftool.prompt false |
Skips the "Launch bc?" question for every file |
git config --global mergetool.prompt false |
Opens merges without asking first |
git config --global mergetool.keepBackup false |
Stops Git leaving .orig files after merges |
git config --global mergetool.bc.trustExitCode true |
Lets Git read whether you saved the merge |
Everyday Commands
Compare your working changes
Run git difftool with no arguments to step through every modified file. Each one opens in Beyond Compare, and the next opens when you close the current window.
Compare a single file against another branch
git difftool main -- src/app.js
Compare two whole branches at once
Stepping through files one by one gets slow on large changes. Directory diff mode copies both versions into temporary folders and opens them as a single Folder Compare:
git difftool --dir-diff main feature/login
You see every changed file in one tree, can open any of them, and get a quick sense of the overall change. This is one of the best reasons to pair Git with Beyond Compare.
Resolve merge conflicts
When a merge or rebase stops with conflicts, run:
git mergetool
Beyond Compare opens a merge view with your version, their version, the common ancestor and the output. Take changes from either side block by block, or type a fix directly in the output pane. Save and close, and Git marks the file as resolved.
Tip: In the merge window, use the toolbar buttons to jump between conflicts rather than scrolling. It keeps your place and makes it hard to miss one.
Comparing Specific Commits
Difftool accepts the same revision syntax as git diff, which opens up handy shortcuts:
git difftool HEAD~1 HEAD
git difftool v1.4.0 v1.5.0 -- docs/
git difftool --staged
The first shows what the last commit changed. The second compares two tagged releases, limited to the docs folder. The third reviews what you have staged before you commit, which is a good habit for catching stray debug lines.
Reviewing a Pull Request Locally
Web-based review tools are fine for small changes, but a large pull request is easier to read in a proper comparison window. Fetch the branch, then compare it against the point where it left the main branch:
git fetch origin feature/login
git difftool --dir-diff main...origin/feature/login
The three dots tell Git to compare against the common ancestor, so you see only the changes made on the feature branch. Inside Folder Compare, open each changed file, read it side by side, and make notes as you go. Because the panes are editable, you can even test a small fix locally before suggesting it.
Settings for One Repository Only
The commands above use --global, which applies to every repository on your computer. If you want Beyond Compare in one project only, perhaps because a team standard requires a different tool elsewhere, run the same commands inside that repository without --global. Git stores them in the project's own config file, and the global setting stays untouched.
You can also check what Git currently uses with git config --get diff.tool and git config --get merge.tool. If the answer is not bc, a repository-level or system-level setting may be overriding yours.
Reading Diffs Faster
A few habits make reviews quicker once the tools are connected. Turn on "Show differences only" in the view menu to hide unchanged lines on long files. Set rules to treat whitespace as unimportant when a commit reformats code. Use the next and previous difference buttons, or their keyboard shortcuts, rather than scrolling. And when a file has been moved and edited, the directory diff view makes it obvious, because you see both the old and new paths in one tree.
Using It With Other Tools
The same idea works beyond Git. Subversion clients, Mercurial and Perforce can all launch an external diff program. Graphical clients such as SourceTree, TortoiseGit and Visual Studio let you pick Beyond Compare from a list or point to bcomp in their settings.
Troubleshooting the Setup
Git says the tool is not available
Git cannot find the executable. On Windows, check the difftool.bc.path value and make sure the file exists there. On macOS, confirm the command line tools were installed. Running which bcomp should print a path.
The diff window flashes and closes immediately
You may be pointing at BCompare.exe instead of bcomp.exe. The main program returns at once, so Git thinks you are finished. Switch the path to the helper.
Merges open without the base pane
Three-way merging needs the Pro edition. If your trial has ended on a Standard license, Git still opens a comparison, but without the ancestor view.
Pros
- Git recognizes Beyond Compare by name, so setup is short
- Directory diff shows a whole branch change in one window
- Editable panes let you fix small issues during review
Cons
- Three-way merge needs the Pro edition
- Windows paths must be updated if you install elsewhere
- Temporary folders in directory diff can confuse first-time users
Frequently Asked Questions
What name does Git use for Beyond Compare?
Git uses the short name bc. Set diff.tool and merge.tool to bc and Git passes the right arguments automatically.
Which file should I point Git at on Windows?
Point it at bcomp.exe in the Beyond Compare install folder. It waits for the comparison to close before returning control to Git.
Can I compare two branches as folders?
Yes. Run git difftool --dir-diff followed by the two branch names to open every changed file in a single Folder Compare.
Do I need the Pro edition for Git?
Not for diffs. Standard works as a difftool. You need Pro, or an active trial, for three-way merges with git mergetool.
How do I stop Git asking before each file opens?
Run git config --global difftool.prompt false. Use mergetool.prompt false to do the same for merges.
Conclusion
Pairing Git with Beyond Compare takes only a couple of commands, and it pays off every single day. First set diff.tool and merge.tool to bc, point Windows at bcomp.exe, and turn off the extra prompts. Use directory diff to review whole branches at once, and lean on the Pro merge view for conflicts. Reviews become faster, clearer and far less tiring than reading raw patch output in a terminal.
