What's a good (free) visual merge tool for Git? (on windows)
Solution 1
On Windows, a good 3-way diff/merge tool remains kdiff3 (WinMerge, for now, is still 2-way based, pending WinMerge3)
See "How do you merge in GIT on Windows?" and this config.
Update 7 years later (Aug. 2018): Artur Kędzior mentions in the comments:
If you guys happen to use Visual Studio (Community Edition is free), try the tool that is shipped with it: vsDiffMerge.exe
. It's really awesome and easy to use.
Solution 2
I've also used Meld. It's written in python. There is an official installer for Windows that works well.
Install it and then set it as your default mergetool.
$ git config --global merge.tool "meld"
$ git config --global mergetool.meld.path "C:\Program Files (x86)\Meld\Meld.exe"
If using a GUI GIT client, try the following (instructions for SourceTree, adjust accordingly)
- In SourceTree, go to Tools/Options/Diff
- In
External Diff Tool
, choose Custom - Enter
C:\Program Files (x86)\Meld\meld.exe
in Diff Command and$LOCAL $REMOTE
in Arguments - In
Merge Tool
, choose Custom - Enter
C:\Program Files (x86)\Meld\meld.exe
in Diff Command and$LOCAL $MERGED $REMOTE
in Arguments
Solution 3
I've been using P4Merge, it's free and cross platform.
Solution 4
I don't know a good free tool but winmerge is ok(ish). I've been using the beyond compare tools since 1999 and can't rate it enough - it costs about 50 USD and this investment has paid for it self in time savings more than I can possible imagine.
Sometimes tools should be paid for if they are very very good.
Solution 5
- TortoiseMerge (part of ToroiseSVN) is much better than kdiff3 (I use both and can compare);
- p4merge (from Perforce) works also very well;
- Diffuse isn't so bad;
- Diffmerge from SourceGear has only one flaw in handling UTF8-files without BOM, making in unusable for this case.
Related videos on Youtube
Tal Galili
Statistics, blogging, and the hope for a happy long life.
Updated on December 06, 2020Comments
-
Tal Galili over 3 years
A similar question was already asked, but for Ubuntu.
It would help to know if the tool is free as in beer or as in liber.
Also, up and downs of the tool would be nice to know.
-
eckes almost 13 years+1 for mentioning paid options.
-
Preet Sangha almost 13 yearsI have heard many good things about Araxis too.
-
Preet Sangha almost 13 yearsDepite favouring BC, I'm going to check this tool out.
-
VonC almost 13 years@Preet: BC remains the best ;) But for a free tool (multi-platform at that), kdiff3 is not bad.
-
Leif Gruenwoldt almost 10 yearsI think the question was about resolving merge conflicts.
-
flteam over 9 yearsIs this still free? It doesn't appear to be free at all.
-
Daniel Little over 9 yearsYes, still 100% free, but their download page hides it a little.
-
Warpzit over 9 yearsbut it defintly isn't that good either :) I tend to find it easier to use my regular code editor.
-
VonC over 9 years@Warpzit I agree there is a bit of a learning curve, but I am used to it now ;)
-
Daniel Tonon about 9 yearsThanks, Meld is really nice :) It's really clear and easy to see whats going on. Thanks for posting the install instructions. I would have been lost without those.
-
John about 9 yearsIt is free as Daniel said but when you run the installer, you need to disable all of the options except the "Visual Merge Tool". Otherwise, it will prompt you to connect to a Perforce server. Works great with SourceTree.
-
tempestSA almost 9 yearsIf you are using cygwin/babun, replace the 2nd option with:
git config --global mergetool.meld.path "/cygdrive/c/Program Files (x86)/Meld/Meld.exe"
-
Mark C almost 9 years+1 for the git config, I used it with P4Merge below:
git config --global merge.tool "p4merge" && git config --global mergetool.p4merge.path "C:\Program Files\Perforce\p4merge.exe"
-
Mark C almost 9 yearsOnce installed configure as mergetool using:
git config --global merge.tool "p4merge" && git config --global mergetool.p4merge.path "C:\Program Files\Perforce\p4merge.exe"
-
Pacerier over 8 yearswinmerge is lousy. The UI makes it hard to tell the left from the right.
-
Pacerier over 8 years@Gordolio, Is there a "simple" or "low resolution" UI for meld? The graphics is a bit too beautiful which totally chokes on huge files.
-
Shridutt Kothari over 8 yearsThanks for pointing open source options here!
-
rleelr about 8 yearsThen run: git config --global merge.tool "kdiff3"; git config --global mergetool.kdiff3.path "C:\Program Files\KDiff3\kdiff3.exe"
-
Stephen Hosking almost 8 yearsI used WinMerge for years and think it's great. Then I switched to git for version control and needed a GUI for version comparison. First I tried Meld for and found it good, but short of features. Beyond Compare has solved it for me, and I'm quite happy to pay for it.
-
Stephen Hosking almost 8 yearsI tried Meld and it was good, with some nice visuals, but in the end went for Beyond Compare, with pay, and have been very happy. One minus of Meld is that the buttons don't give mouseover descriptions. Another - Beyond Compare provides buttons to move from one difference to the next. Another - Beyond Compare shows the file paths in the window title bars. Meld was certainly "Good enough", but I'd rather pay for Beyond Compare. (And I have no affiliation with Beyond Compare).
-
mindplay.dk almost 8 yearsTortoiseGitMerge is actually quite good - I don't know kdiff3, but have never been unhappy or missed anything in TortoiseGitMerge, it lets me do both two and three-way merges very quickly and intuitively.
-
Lazy Badger almost 8 years@mindplay.dk - TortoiseGitMerge is (mostly) ol' good TortoiseMerge under the hood
-
Artif3x about 7 yearsTrying to figure out how to download the windows version of p4merge using your link seems quite a task. There's no clear download link that I can see.
-
user4674453 almost 7 yearswinmerge looks ugly on high resolution screen and useless for merge. After I've removed line from the right file, I was unable used the tool having error message.
-
VonC almost 7 years@user4674453 regarding the resolution, see blogs.msdn.microsoft.com/sqlreleaseservices/… (replace ssms by winmerge name and path)
-
user4674453 almost 7 years@VonC, not my job. I've chosen another tool instead.
-
VonC almost 7 years@user4674453 OK. What did you choose on Windows? Beyond Compare?
-
user4674453 almost 7 years@VonC, I've chosen Diffmerge from SourceGear. It is mentioned in one of answers.
-
andrew.rockwell over 6 yearsP4Merge doesn't support --dir-diff, which is a dealbreaker for me
-
andrew.rockwell over 6 yearsTortoiseMerge doesn't support dir-diff
-
User over 6 yearsLink is dead. Updated link: perforce.com/downloads/visual-merge-tool
-
Artur Kędzior almost 6 yearsIf you guys happen to use Visual Studio (Community Edition is free) try tool that is shipped with it:
vsDiffMerge.exe
. It's really awesome and easy to use. -
VonC almost 6 years@ArturKędzior Thank you. I have included your comment in the answer for more visibility.
-
mosh about 5 yearsmeld is too slow on windows, faster ones are: kdiff3, winmergeu