DataSwap Fast file & data format converters, no signup

CSV to Markdown Table Converter

Paste CSV below and get a ready-to-paste Markdown table, with pipe characters in your data safely escaped so they can never be mistaken for a column separator. Nothing you paste is uploaded — the conversion runs entirely in your browser.

Turn a CSV export into a clean Markdown table

The first row of your CSV becomes the header row; every row after it becomes a data row. The parser is quote-aware — it correctly handles fields that contain the delimiter itself, embedded newlines, and doubled "" escaped quotes — which is exactly the kind of real-world CSV that a naive split(",") approach corrupts. Any | character inside a cell's own value gets escaped to \|, since an unescaped pipe would otherwise look like a new column boundary to a Markdown renderer and break the table.

Worked example

Input (75 characters, 3 columns, 2 data rows):

name,price,notes
Widget,9.99,"Ships in 2 | 3 days"
Gadget,14.50,Backordered

With Align columns on, this converts to:

| name   | price | notes                |
| ------ | ----- | --------------------- |
| Widget | 9.99  | Ships in 2 \| 3 days |
| Gadget | 14.50 | Backordered           |

Notice the pipe inside "Ships in 2 | 3 days" comes out as Ships in 2 \| 3 days — escaped, not raw — so the table still renders as three clean columns instead of the pipe being read as a fourth column boundary.

Frequently asked questions

Does this handle commas or pipes inside quoted CSV fields?

Yes. This isn't a naive split(",") — the parser tracks quote state character by character, so a field like "Ships in 2, maybe 3 days" (a comma inside quotes) or "has a | pipe" stays one field instead of getting sliced apart. It also unescapes doubled "" quotes and reassembles fields that contain embedded newlines, exactly per the CSV spec.

Why are pipe characters in my data shown as \| in the output?

Markdown tables use `|` to separate columns, so a literal pipe sitting inside a cell's own text would look like a new column boundary to any Markdown renderer and corrupt the table. This tool automatically escapes every `|` inside a cell's value to `\|`, which renderers display as a plain pipe character without breaking the table structure.

Is my CSV uploaded anywhere?

No. Parsing and table generation both happen in your browser with a small hand-written parser — nothing you paste is sent to a server, stored, or logged. That's true for every tool on this site.

What happens if my rows have different numbers of columns?

Ragged rows are padded out to match the header row's column count, with missing cells left empty, so the table stays valid Markdown instead of breaking alignment partway down.

Which delimiter should I pick besides comma?

Choose semicolon if your CSV came from a European-locale spreadsheet export (common when the decimal separator is a comma), or tab if you're actually converting a TSV file. The first row is always treated as the header row.