I need a tool to compare 2 binaries. The files are quite large. Some freeware or trial tools I found on the Internet are not convenient to use for large files. Can you recommend me some tools?
Asked
Active
Viewed 4.2e+01k times
6 Answers
241
If you want to find out only whether or not the files are identical, you can use the Windows fc
command in binary mode:
fc.exe /b file1 file2
For details, see the reference for fc

Jason
- 9,408
- 5
- 36
- 36

Mike Woinoski
- 3,123
- 1
- 16
- 15
-
2for the same purpose - only whether files are identical or not - a portable app Duplicate File Finder works good enough. Particularly for big files like .iso files. – RuntimeException Oct 14 '15 at 14:03
-
14this should be the accepted answer, since this is windows native and not an addition 3rd party app – LilaQ May 09 '17 at 00:31
-
2this just shows a list of bytecodes - there is also a "comp" tool in the command-line, but that one seems to require files to be of same size – George Birbilis Jan 10 '18 at 10:26
133
A few possibilities:

mgutt
- 5,867
- 2
- 50
- 77

Polynomial
- 27,674
- 12
- 80
- 107
-
4I read in the notes of vBinDiff that "unlike diff, it works well with large files (up to 4 GB)." So its suitability for working with large files depends on your definition of "large". Also, I found it would mysteriously not start up under windows 7 x64. – intuited Aug 21 '12 at 19:15
-
34Bare in mind that VBinDiff is a CLI program, so if you just try to run it on Windows, it will either appear not to start, or will very briefly show a command prompt window, which quickly disappears. Open up a command prompt and run the program from there to see what arguments it accepts, and then use it from the command prompt accordingly. – nonoitall Oct 14 '12 at 00:37
-
2
-
When I tried using vBinDiff to compare two 1.4 GB files, it croaked. Neither can WinDiff handle such files. – ThreeBit Apr 25 '13 at 08:17
-
@intuited I too found this quite humorous, although I found that it does work with files larger than 4 GB -- you just can't see diffs past 4 GB. That was enough for my purposes, although it would be great to have true LFS. – pattivacek Mar 25 '15 at 16:10
-
Anyone know were we can get WinDiff from? The link is just to the wikipedia page. There's a link to XPsp2 support tools there (which includes it), but that will only install on XP. – UpTheCreek Oct 16 '15 at 11:48
-
VBinDiff is AWESOME! Thought it is CLI, it is easy to use! Except maybe I had to search what RET key is xD It turns that it is the Enter key. – Ghasan غسان Dec 06 '15 at 02:49
-
4vBinDiff doesn't seem to deal with inserted bytes at all, so it's really not much better than HxD except that it shows you all the changes in red. – endolith Feb 11 '16 at 21:13
-
1VBinDiff allows you to freeze one of the two scroll areas and when you make them sync again by scrolling the other one byte at a time it shows the same parts in white and diffs in red. So it is more of a manual tool, but with visual aid – George Birbilis Jan 10 '18 at 10:25
25
Total Commander also has a binary compare option:
go to: File \\Compare by content
ps. I guess some people may alredy be using this tool and may not be aware of the built-in feature.
-
1This doesn't understand inserted content like a text diff tool, though, only changes to bytes. – endolith Feb 11 '16 at 21:16
-
3@endolith and another thing to mention is that `Total Commander` costs $42 USD. – c00000fd Oct 14 '18 at 00:01
19
My favorite "swiss knife" is Beyond Compare from http://www.scootersoftware.com/

Boris Ivanov
- 4,145
- 1
- 32
- 40
-
3
-
1
-
1@BorisIvanov: It probably helps to mention that `Beyond Compare` is a paid software that will work only for 30 days. After that you'll have to get the license that costs $60. – c00000fd Oct 13 '18 at 23:54
-
strange things but version I have downloaded from official site always working even after trial period. no hacks. – Boris Ivanov Oct 14 '18 at 12:55
-
Beyond Compare doesn't appear to have binary diffing capability, which is what the question was about. – Andrew Arnott Sep 03 '22 at 14:45
-
15
I prefer to use objcopy to convert to hex, then use diff.

BobC
- 1,978
- 3
- 24
- 26
-
4Useful answer. The output file size is about 3 times as big as the input file. This command will convert a binary file to hex. `objcopy -I binary -O ihex
`
12
In Cygwin:
$cmp -bl <file1> <file2>
diffs binary offsets and values are in decimal and octal respectively.. Vladi.

Vladi
- 464
- 4
- 6