File format

DOC - Microsoft Word Binary Document

DOC is the binary format Word wrote for two decades before DOCX. Old files still turn up constantly, and they hide more metadata than their authors ever realised.

DOC is the format Microsoft Word saved to from the late 1980s until Word 2007 replaced it with DOCX. It is a binary format, which simply means the file is machine data rather than readable text — open one in a text editor and you get mostly gibberish with fragments of your sentences floating in it. Enormous numbers of DOC files still exist in archives, email attachments and shared drives, so the format matters long after it stopped being the default.

How a DOC stores a document

A DOC file uses a container Microsoft called the Compound File Binary Format — in effect a tiny filesystem inside a single file, with its own directory of named streams. One stream holds the text, another the formatting tables, others the embedded pictures and objects. The specification grew organically across a dozen Word releases, which is why the format is complicated enough that reading it correctly is a genuine achievement for any program that is not Word.

That design has one notorious consequence. Because a stream can be edited in place, Word historically appended and patched rather than rewriting, so deleted text could remain in the file even though it no longer appeared on the page. Fast-save behaviour made this routine. A DOC recovered from an old drive can therefore contain paragraphs that were cut long before it was sent.

DOC also has no built-in compression, so a document with a few photographs in it grows quickly — often several times the size of the equivalent DOCX.

What metadata a DOC carries

DOC stores its metadata in summary information streams inside the compound file. The visible set is much the same as DOCX: Title, Subject, Author, Keywords, Comments, Last Modified By, and the created and modified timestamps.

The document summary adds Company, Manager, Category, the page, word and character counts, the application and version that wrote the file, Total Editing Time in minutes, and a Revision Number. Word also kept a list of previous authors and the local paths a document had been saved to, which is how DOC files have historically leaked names, network share names and directory structures.

If you are reading metadata from an old DOC, treat everything in it as potentially more informative than intended. This is the format that taught organisations to strip document properties before publishing.

When to use DOC

Do not choose DOC for anything new. DOCX is smaller, better specified, supported everywhere DOC is, and does not carry the fast-save residue problem. Every current word processor writes DOCX by default for good reason.

The one case for touching DOC is compatibility with genuinely old software that cannot read anything else. Otherwise, treat a DOC as something to convert: open it, check that the layout survived, save it as DOCX or export it to PDF, and read its metadata once before you pass it on.