What a CHM actually is
A .chm is a small filesystem. Microsoft called it ITSS: a header, a directory of entries, and one or two content sections — section 0 stored plain, section 1 compressed with LZX. Inside are ordinary HTML pages, stylesheets and images, plus a few metadata streams whose names begin with # or $.
Two of those streams matter here. #SYSTEM records the help file's title and its default topic — the page a viewer should open first. Without it, a reader has to guess, and guessing alphabetically usually lands on a stylesheet. The .hhc file is the contents tree, written as an HTML sitemap of nested <UL> and <LI> elements with <OBJECT type="text/sitemap"> entries inside.
Real .hhc files are famously malformed — unclosed list items everywhere — so they are parsed with the browser's own HTML parser, which recovers from that the same way the original help viewer did. An XML parser would simply refuse the file.
Reading a page
Each page's stylesheets and images are resolved against the page's own path inside the help file and replaced with the CHM's own bytes. Links between topics work: the page is shown in an iframe that is same-origin but has no allow-scripts, so nothing in it can execute, while the tool itself can intercept a click and navigate to the linked topic. A link that points at the open internet is not followed, and an injected default-src 'none' policy means it cannot be fetched even by accident.
About the compression — plainly
The tool reports what the file uses: LZX with its window size and reset-block count, or nothing at all if everything sits in the stored section.
The LZX decoder here was written from the [MS-PATCH] specification and from libmspack's lzxd.c. Its bitstream reader, canonical Huffman decoding, uncompressed blocks and x86 filter are unit-tested. Its verbatim and aligned block decoding have never been run against a file produced by Microsoft's own compressor, because no offline corpus was available to test against.
So if a page fails to unpack, this tool shows the specific error and refuses to render anything. It does not put the recovered bytes on screen. Garbage that looks like a page is worse than an honest failure, because you cannot tell the difference. If a real help file fails here, that is worth reporting — the bug is ours.
Also available
Every page listed with its size and which section it lives in, the compiler that built the file, and the ITSS directory details. To pull the files out instead of reading them, use the CHM Extractor.
Privacy
The help file is opened in your browser and never uploaded.
Tiny Online Tools







