share
Stack OverflowWhat is a good Windows hex editor / viewer?
[+188] [21] basszero
[2008-08-13 22:24:28]
[ windows editor hex endianness hex-editors ]
[ http://stackoverflow.com/questions/10426/what-is-a-good-windows-hex-editor-viewer ] [DELETED]

I am in need of a hex editor / viewer (viewer is more important than editing, but a plus if it can edit) for Windows.

See KHexedit [1]

Requirements:

"Nice to have" features:

(41) How is this not constructive? Don't programmers need a good Hex editor? And who better to recommend a good one than a fellow programmer? +1'd instead. - Juan Luis Soldi
(15) I agree! It's a good question and I'd far rather get an answer from Stack Overflow than other sites - +1! - Nick
(12) The best questions on SO are often closed by mods. Sorry mods, you guys are dicks. And this question is VERY CONSTRUCTIVE. That's why we are hitting it so often from search engines. - Gabriel Magana
(14) -1 Robert Harvey. Dumb closure. Can somebody re-open this VERY constructive question? - Brendan Byrd
(6) This is a bit ridiculous that this is closed, when the closing moderator has one of the most useless answers ever still up here: stackoverflow.com/a/2754499/311525. This question will help people day to day 1000x more than a stupid hack to not use semicolons. WTF is this site supposed to be, real help or stupid hacks? - Scott
I just answered another hex editor question and this question came up in the "Related" column. My vote is psPad. I don't know how they stay free, but if I weren't primarily in linux, I'd donate money to them. - Chris K
Don't understand the logic behind this close. Programmers and tools don't exist in separate vacuums. But I guess some mods simply see the word 'good' and default into a close vote. - Clairvoire
Why is there no way to reopen the question? - this is a great example of how the site lost its way through shift from overtly noisy people with a twisted agenda. Worst case - turn it into a wiki. Best case: shoot destructive admins - John Nicholas
[+96] [2008-09-19 14:33:03] Ace

HxD is great. :)

http://mh-nexus.de/en/hxd/


(4) HxD is the best. I use it exclusively for hex editing. - George Edison
(1) This has a pretty interface, but doesn't look like it has as many features as others? Binary file comparison is nice, and something I would use, but it doesn't seem to work the same way as other diff utilities (side-by-side view, synchronized scrolling, etc). I don't see a convenient way to edit or view individual bits. - endolith
(3) I once tested several hex editors trying to search for a pretty large amount of hex data in a binary file, HxD is the only capable one. - XTL
(2) HxD is fantastic, and the only one able to open massive files (gigabytes) with ease I've ever seen. - Django Reinhardt
(4) It's lacking some features i find important. Okteta ( within the KDE package ) and Bless ( which needs Mono/GTK# installed ) have these. Being able to view the next set of hex as different data types really is a must for me! - DavidG
1
[+29] [2008-08-13 22:28:29] Derek Park [ACCEPTED]

I've never found one that I really love. I tend to go searching every time I need one. However, I will point you toward two links:

Wikipedia: Comparison of Hex Editors [1]
Wikibooks: Windows Hex Editors [2]

[1] http://en.wikipedia.org/wiki/Comparison_of_hex_editors
[2] http://en.wikibooks.org/wiki/X86_Disassembly/Analysis_Tools#Windows_Hex_Editors

(2) +1 for first link. Second link has succumbed to link rot. - Oorang
(1) Looks like the Wikibooks article had been merged into another; updated the link. - Ben Blank
2
[+20] [2010-09-09 09:02:14] Samuel Jack

If you have Visual Studio, you already have a Hex Editor (albeit fairly basic and without some of the features mentioned):

  1. Do File > Open then select your file.
  2. Don't click Open, but click the down arrow next to it.
  3. Select Open With then choose the Binary Editor.

Visual Studio Hex Editor

Source for this tip: http://stackoverflow.com/questions/1724586/can-i-hex-edit-a-file-in-visual-studio


3
[+17] [2008-08-13 23:32:33] Jon Galloway

If you already use Notepad++ there's a Hex Editor plugin [1].

[1] http://sourceforge.net/projects/npp-plugins/files/Hex%20Editor/

(3) Recent versions always try to remove it as incompatible, though. The one thing I really liked about it was the ability to show in binary, for swapping individual bits in EEPROMs. - endolith
4
[+14] [2008-08-13 22:35:15] bruceatk

I use HEdit [1]. I've used it for years. It's fast and free. It has most of the features you want. The version that I have is 3.0. Updated: The latest version is 3.2 and it is not free anymore. It is now $99.00.

Hex Workshop [2] has all the features you want (like Integrated Structure Viewer) but it's $90.

[1] http://www.yurisw.com/HEdit.htm
[2] http://www.hexworkshop.com/

Just tried HEdit, and it worked really well. - Jared Harley
(3) And Hex Workshop is now $90. - I. J. Kennedy
(4) The link for HEdit seems to be broken. However, HEdit is available at softpedia.com/progDownload/HEdit-Download-120464.html - larsm
Does HEdit work in Windows 7? - endolith
I haven't had any issues with it. I haven't install it on Windows 7. I did an upgrade to Windows 7 from Vista. It installed on Vista fine. - bruceatk
(4) HEdit isn't exactly free. Immediately after installing it, it says the following: "Your copy of HEdit will be operational for four weeks. After that period, you can either purchase a license, or uninstall HEdit from your machine. Consult HEdit on-line help for information on how to order the license." - Senseful
The version that I have is 3.0. It looks like Yuri isn't making it available anymore. What version did you install. It sounds like you have an older version. - bruceatk
I am a long time user of HEdit and I confirm it's not free ($99). HEdit was developed with edition of huge files in mind. The counterpart is that it keeps the file opened which is painful if you use it as a viewer while modifying the file externally (such as programmatically). - Serge - appTranslator
@Serge. I have updated my entry. I don't understand the history of all this, but it appears that in 2004 it cost $99. I also couldn't download it, or register the 1.x version I had. I contacted Yuri about it and he said it was no longer available. Somewhere around 2008 3.0 was available and it was free. In 2010 it wasn't available anymore. In 2011 it is now at version 3.2 and costs $99.00. - bruceatk
5
[+14] [2008-11-13 22:51:37] MattG
gvim -b file.bin

:%!xxd to view hex

:%!xxd -r to convert back


Or just use the "Tools" / "Convert To Hex" menu item! - James Anderson
(1) Asked for windows. I believe gvim is *nix based. - mklauber
(5) Nope, there's an official Win32 distribution of gvim available at vim.org - Rytmis
(1) Worked great for viewing, not so handy at editing. - Flame
6
[+10] [2008-08-13 23:57:08] OJ.

UltraEdit [1] is a wicked hex editor, as is HIEW [2] (though HIEW does look like DOS, which might turn you off). Unfortunatley they're both shareware, so require a license.

If you're looking for free, you could take a gander at Cygnus [3]. It's not huge on features, but it's quick and it works.

[1] http://www.ultraedit.com/products/ultraedit.html
[2] http://www.hiew.ru/
[3] http://www.softcircuits.com/cygnus/fe/

7
[+9] [2010-01-13 07:12:05] Flynn

I spent some time looking for a good editor a while ago and finally settled on ICY Hexplorer:

http://hexplorer.sourceforge.net/

Free/GPL and has some other "advanced" features like custom data structures, pixel view, etc.


(1) I second ICY Hexplorer. It is simple to use and the pixel view / hex-value-colorization makes looking at the data much easier. - Mark Lodato
Looked awesome if I had a magnifying glass. I use a monitor with high resolution and there is no way to change font size. But it's open source, so mb if I get the time I could add this as a feature. - TamusJRoyce
(2) @TamusJRoyce I had the same problem (font size). Choose some other font such as Fixed Roman Large instead of the standard Fixed Roman. On a really large monitor maybe even that ain't enough, but it worked for me :-). - Omar Kohl
why when I hit ENTER, does it type 0D? What uses just 0D? Linux uses 0A, and Windows uses 0D0A doesn't it? - barlop
8
[+7] [2008-08-13 22:28:47] Patrick

I'm a big fan of fhred [1]. It's free and it's met most of my requirements over the years.

[1] http://frhed.sourceforge.net/

This is what I've been using for a while, too. It has a "manipulate bits" menu entry to edit individual bytes when setting flags in EEPROMs, etc. New link: frhed.sourceforge.net - endolith
Your link is dead. - Mark
Thanks for the heads up, Mark. Link fixed. - Patrick
9
[+5] [2010-09-25 17:17:31] Harald Maassen

Many of the above recommended hex editors (including HxD) do not meet the OP's requirements:

  • View data at cursor as: byte, short, int, long, float, double (signed/unsiged where applicable)
  • Configure the endiance for multi-byte decoding

A free solution that does is KDE's Okteta. A Windows installer for KDE can be found here [1]. Okteta is part of the kdesdk module (KDE ≥ v4.6) or the kdeutils module (KDE < v4.6).

[1] http://windows.kde.org/

10
[+4] [2009-06-24 14:39:20] pjbeardsley
(1) That's what I've used, but I don't like it because it uses unintuitive GUI design. E.g. to select a range of bytes to copy, I'd expect to just click-and-drag with the mouse, like in any other program. Instead, you click the first byte, Ctrl-B (block mark), select the last byte, Ctrl-B again. Shift-arrow-keys does select a block as I'd expect though. But then, data you copy can't be pasted into other programs for some reason. - Craig McQueen
I use it because of the nice conversions to various types like Int32 and Double; however every time I fire it up I think, "I need to rewrite this using WPF and give it a much better UI experience." - codekaizen
11
[+3] [2008-08-14 00:00:04] Andrew Grant

I'd strongly recommend UltraEdit. It's not free (beyond the 45 day trial), but it's very very good and I don't mind paying for something I use so regularly.

Some of my favorite/most used features;

  • Hex editing / viewing (inc find/replace/insert/remove)
  • Source code highlighting / formatting
  • Integrates with the Windows shell
  • Tabbed interface
  • Basic file/folder diff built in (you can pay for a more expensive diff package)
  • List item Macros / Scripting
  • Freely converts back and forth between line endings and ANSI/UTF-8/UTF-16 etc

12
[+3] [2010-02-14 01:01:20] anelson

When I need a hex editor on Windows, I always reach for WinHex [1].

It's not free, but it meets all your other requirements, and does about a million other things besides.

I write and maintain software that images logical volumes under Windows, so Winhex's ability to open a physical disk or logical volume is very handy. It also has built-in decoders for common on-disk structures like NTFS MFT, MBR, etc. Building your own is easy too.

I've tried all sorts of free editors/viewers, and always come back to WinHex.

[1] http://www.x-ways.net/winhex/

13
[+2] [2008-08-13 22:31:58] superjoe30

I can's swim in Windows without PSPad. [1]

  • Fast
  • Tabs
  • Syntax hilighting
  • Hex editor
[1] http://www.pspad.com/

14
[+2] [2011-07-04 09:34:28] MaxMuen

From personal experience i can recommend 010 Editor, a very powerful hex editor. The unique feature of 010 is the ability to create templates so that you can label and find information in you hex file.


15
[+1] [2010-02-13 08:10:10] Jeffson

It's not my everyday hex editor, it's a bit specialized, but MadEdit is the best Unicode editor I've seen, especially when dealing with weird encodings or a file that's gotten borked via multiple encodings. And it has a hex mode which is especially good at making it obvious exactly which bytes are being interpreted as which characters. It's nothing special in hex mode if you're just editing bytes or ASCII, but it's free (GPL), fast with large files, multi-platform, and is great when you need unicode support.


16
[+1] [2011-04-12 01:22:01] E.U.A.

You can try wxHexEditor at http://wxhexeditor.sourceforge.net

It's open sourced and work on Windows, Linux, OSX...

I write it since there is no good hex editor for huge files and/or devices on Linux. Since I use wxWidgets it works on Windows and OSX too. I am happy if you decide contribute some code...

  • Fast
  • Tabs
  • Multiple Views
  • Tags
  • Disk editor
  • Built-in DisAssembler
  • Allows up to exabyte sized files and devices
  • open sourced
  • cross-compilable

17
[0] [2010-02-14 01:36:06] user271664

I've always used UltraEdit but I've shifted toward Notepad++ recently


(2) Both UltraEdit and Notepad++ have already been mentioned. - froeschli
18
[0] [2010-12-15 18:20:19] Jonathan Wood

One not mentioned is Cygnus Hex Edit at http://www.softcircuits.com/cygnus/. They also have a scaled down version that is free at http://www.softcircuits.com/cygnus/fe/.

And in addition to that, I've posted about a free hex editor control with source code for MFC at http://www.blackbeltcoder.com/Articles/userctrls/mfc-hex-editor-control.


Actually was mentioned already. - shytikov
19
[0] [2010-12-30 07:58:10] froeschli

Although a lot of answers have already been provided, I would like to mention FileBrowser [1] with an integrated hex editor/viewer. The viewer and editor are separate plugins with different file handling.

From the HEX Viewer description on the website:

Chapter 1. Overview

A simple FileHandler which allows the inspection of arbitrary binary data files.

It will display the contents of the file in a hexadecimal and an ASCII form but will not load the files contents into memory. It rather always reads those bytes from the underlying file whenever it is necessary to display them.

This has the following consequences:

The viewer allows a “live” view on the opened file and will reflect changes to that files contents immediately upon redisplay.

The file is opened in read only mode which allows other processes to modify it. It will prevent the deletion of the file however.

It allows inspecting even huge files which could never be loaded into memory.

The FileHandler is a pure viewer and thus doesn't support any modification of data or saving it in any form.

From the HEX Editor description on the website:

Chapter 1. Overview

A simple FileHandler which allows editing of arbitrary binary data.

It can be used to modify the contents of any file on a byte by byte level. The files contents are fully loaded into memory and presented in a hexadecimal and ASCII table, a way very common among HEX editors.

ASCII control characters (those bytes with a value below 0x20) are displayed in a lighter color in the HEX table than other bytes. They display a tooltip text with the meaning of that byte when hovering the mouse cursor above them.

Modification of bytes is possible both in the per byte hexadecimal table as well in the ASCII line to the right of that table.

Modifying a table cell (either HEX or ASCII) will require to press either TAB or ENTER to confirm the change.

Modifying in the ASCII cell will only change those bytes whose ASCII representation has changed, thus preventing accidentially resetting non-ASCII bytes of that line.

Individual bytes can be deleted by selecting the byte to delete and pressing the according button. New bytes can be inserted at the position of the currently selected byte, thus shifting that byte (and all following content) to the end by one.

As this FileHandler supports modification and saving of the loaded data, it is an editor by nature.

In order to provide a true editor experience however, it is necessary to load the entire files contents into memory to avoid having to make changes on the underlying file when editing. For large files this might result in memory issues though.

[1] http://boarderzone.net/products/FileBrowser/en/index.html

20
[0] [2011-09-10 03:33:51] Ali Kıran

CI Hex Viewer [1] fits my expectations

[1] http://www.fileguru.com/CI-Hex-Viewer--Mac-OS-/info

(1) This is a MacOx software only, while the OP asked for a Windows app. - barjak
21