← Writing / Website

Recovering a site when only the HTML remains

Start with a byte-for-byte baseline, then separate content from its repeated page shell.

· Note · 1 min read

The live web directory contained HTML, CSS, JavaScript, and images, but no Eleventy source or Git history. The first job was to preserve what was actually being served.

The recovery sequence was deliberately boring:

  1. Snapshot the entire production directory outside the web root.
  2. Record a SHA-256 manifest of every file.
  3. Reconstruct a separate Eleventy project, keeping article bodies as HTML.
  4. Compare every generated file against that manifest.
  5. Commit the matching baseline before changing the design.

All 20 deployed files matched byte for byte. That includes the awkward bits: two versions of Uses, two 404 pages, and a literal template placeholder in an old error page.

That last one is a useful trap. A recovered page can contain {{ requested_url }} as visible text; passing it through a template engine changes it unless it is escaped.

The original Markdown and Git history cannot be recovered from rendered HTML. The words, links, assets, and public routes can. Keeping the article bodies as HTML avoids a conversion step that could silently damage them.

The redesign is built separately. A successful reconstruction does not mean production has been replaced.