Markdown Table Generator

Turn CSV or TSV into a Markdown table with the alignment you want, or convert a table you already have into HTML, JSON or CSV.

Input
Column alignment
Output
Rendered preview

Markdown tables are alignment-blind by default

The separator row under the header does more than mark where the header ends — its colons decide alignment. | --- | is the default (usually left), | :-- | is left, | :-: | is centre, and | --: | is right. Skip the colons entirely and you get whatever the renderer or the site's stylesheet happens to do.

Right-aligning numeric columns is not decoration. Digits are read by comparing place value, and that comparison only works visually when the ones column lines up. A table of figures left-aligned is measurably harder to scan, and the effect gets worse with more rows.

SeparatorAlignmentUse for
| --- |DefaultText
| :-- |LeftLabels, names, identifiers
| :-: |CentreStates, flags, short codes
| --: |RightNumbers, currency, percentages

The pipe character breaks everything

A literal | inside a cell terminates that cell. Any content containing one — a shell command, a comparison operator, a regex alternative, an absolute value — has to escape it as \|. This is the single most common reason a Markdown table renders with shifted columns.

The escape is not free. Some renderers treat \| correctly in table cells and leave the backslash visible elsewhere; a few older parsers do not handle it at all. If your table will be read in more than one renderer, the safest option is often to wrap the content in backticks, which most implementations handle consistently.

Line breaks inside cells do not work

GitHub Flavored Markdown has no mechanism for a hard line break inside a table cell. A <br> tag works in many renderers, and <br> is the usual workaround, but it is HTML in your Markdown — fine on GitHub and in most static site generators, invisible in a renderer that strips tags. If you need multi-line content, a definition list or a set of headings is a better structure than a table.

Tables do not reflow on mobile. A wide table is the classic thing that forces horizontal scrolling on a phone. Wrap it in a scrollable container, or restructure the information as stacked sections. Fewer columns almost always reads better than a table the reader has to pan across.

CSV quoting is its own minefield

Converting CSV to a Markdown table looks trivial until a field contains a comma. Then it depends on whether the file followed RFC 4180: a field with a comma, a quote or a newline must be wrapped in double quotes, and a literal quote inside it must be doubled (""). This tool parses that properly, and reports how many rows it read so you can tell whether it agrees with your data.

Frequently asked questions

Why are my columns shifted?

Almost always an unescaped pipe inside a cell. Replace | with \| — this tool does it for you in Markdown output.

Can I merge cells?

No. Markdown tables have no cell-span syntax. Use HTML if you need rowspan or colspan, and accept that it will not render everywhere.

Does it detect TSV automatically?

Yes. If the input contains no commas but does contain tabs, it is treated as tab-separated. Set the input format explicitly if the guess is wrong.

Is my data uploaded?

No. Parsing and generation happen in this page with no network request.

Privacy. Everything runs locally, so it is safe to paste tables taken from internal documents or customer data.