← All posts

Clean Messy Markdown from ChatGPT, Claude and Gemini

Large language models are great at drafting docs, READMEs and release notes — and terrible at shipping tidy Markdown. Copy a reply from ChatGPT, Claude or Gemini and you may see runs of blank lines, trailing spaces, or formatting that looks fine in chat but breaks in GitHub or your static site.

MD Workbox treats that as a first-class problem.

Why AI Markdown gets messy

  • Chat UIs wrap and reflow text differently from editors.
  • Models sometimes insert decorative spacing for “readability”.
  • Mixed code fences, lists and headings amplify small whitespace bugs.

None of that means your content is wrong. It means you need a cleanup pass before you commit or export.

A simple local workflow

  1. Open Clean Markdown.
  2. Paste the AI output into the left pane.
  3. Keep useful options on:
    • Remove multiple consecutive blank lines
    • Trim trailing whitespace
    • Reduce 3+ newlines to 2
    • Preserve formatting inside code blocks
  4. Copy or download the cleaned result.
  5. Optionally jump to the Editor to preview GFM, KaTeX or Mermaid before export.

Everything in that path runs in your browser. Your draft does not need an account, and the cleanup tool does not upload the body for processing.

When to clean vs edit by hand

Use automated cleanup for spacing and line-break noise. Still review:

  • Heading levels (does the page still have a single clear h1?)
  • Link and image paths
  • Code fence languages
  • Tables that AI flattened into prose

Cleanup is a speed tool, not a substitute for a quick human skim.

Next exports

After the Markdown is clean, convert it where you need it:

Same content, less chat noise, ready for docs or sharing.