Skip to content
DoItJag

Markdown Formatter

Make a README or notes file consistent in one click. The formatter rewrites the Markdown in a single, tidy style: one kind of list bullet, ** for bold, blank lines around headings and lists, and tables with lined-up columns. It uses Prettier, the formatter many open-source projects run on their docs, so the result matches what they expect.

or drop a file here · .md, .txt · up to 20 MB

Options

About the Markdown Formatter

Markdown allows several ways to write the same thing. A bullet can start with a dash, a star or a plus; bold can be two stars or two underscores; tables can have ragged columns. When several people edit one README, these styles pile up and the file gets harder to read and to review. This formatter rewrites the source in one consistent style without changing what readers see.

What it changes

  • Bullets become dashes, and bold uses double stars.
  • Headings, lists, tables and code blocks get one blank line before and after them.
  • Table columns are padded so the pipes line up, and alignment colons are kept.
  • Extra spaces inside sentences are reduced to one.
  • Fenced code blocks are copied exactly, character for character, so sample code is never altered.

Worked example

Press Try an example. The release notes use underscores for bold, star bullets, steps numbered 1) and a cramped table. After Format Markdown, the heading has a blank line under it, __dark mode__ becomes **dark mode**, the bullets turn into dashes, the steps into 1., the table columns line up with the price column still aligned right, and the JavaScript inside the code fence keeps its odd spacing because code is never touched.

Choosing the line break option

Keep as written is the safest choice and leaves line breaks inside paragraphs where you put them. Wrap at the line width suits projects that keep lines short for easier diffs in Git. One line per paragraph is better for text that will be pasted into editors which wrap lines themselves, such as issue trackers or CMS fields.

Under the hood

Formatting uses Prettier, the same open-source tool many projects run before every commit, loaded into this page only when needed. With the same settings, files tidied here pass a project’s Prettier check. Very unusual Markdown extensions, such as custom container blocks, are treated as plain paragraphs and left largely alone.

How to use Markdown Formatter

  1. Paste Markdown, open a .md file or press Try an example.
  2. Choose how paragraph line breaks are handled and the line width.
  3. Press Format Markdown, check the result and copy or download it.

Privacy: how it works

Everything happens in your browser. Your text is not sent to any server.

Frequently asked questions

Will formatting change how my Markdown looks when rendered?

No. It changes only the source: spacing, bullet characters, emphasis markers and table padding. The rendered page stays the same. Code blocks are left byte for byte.

What do the line break options do?

"Keep as written" leaves your line breaks inside paragraphs alone. "Wrap at the line width" re-breaks paragraphs to fit 80, 100 or 120 characters. "One line per paragraph" joins each paragraph into one line, which suits editors that wrap text themselves.

Why did my numbered list change to 1. 1. 1.?

If your list starts with the same number twice, Prettier keeps that style; otherwise it numbers 1, 2, 3. Both render as a correctly numbered list.