Format a Markdown table

Normalize Markdown table spacing and alignment without changing its row data.

freeworks offlinenothing uploaded
ToolMarkdown Table Formatter
Input
Output
Put this on your own site

The frame below runs the same code as this page, in the reader's own browser. Nothing is sent to us, and nothing is sent to you.

Pick a dark background and the text and panels follow it, so the frame stays readable on a dark page.

Preview

How it works

Pipe rows are parsed, padding is recalculated to the widest displayed cell, and a normalized separator row is written. Cell pipes and alignment markers are escaped or retained so the table remains parseable.

  • Left alignment and one-space padding match common GFM style.
  • Formatting changes spacing only.

Worked example

Format a messy Markdown table
Align columns in an unformatted Markdown table
Input
											| Name | Age |
|---|---|
| Alice | 30 |
| Bob | 25 |
										
Output
												| Name  | Age |
| :---- | :-- |
| Alice | 30  |
| Bob   | 25  |
											

When to use this

README tables, release notes, and generated documentation normalize with this pass.

Edge cases

  • A pipe inside a code span can be mistaken for a separator by line parsing.
  • Short rows are padded while extra cells remain separate.
  • A malformed separator may be treated as data.

References