↧ Expand ↧↥ Collapse ↥
Result (updated automatically as you edit the table)

To change a Markdown table you already have, paste its code in File / Paste table data.

Markdown Tables Generator

How to use the Markdown tables generator?

  1. Enter the data. Copy cells from a spreadsheet (Excel, Google Sheets, LibreOffice Calc) or a table on a web page, click a cell and press Ctrl+V: the table grows to fit them. Or click a cell and type: typing replaces its text, while a double click or Enter edits the text that is there (Esc or a click elsewhere ends the edit). Tab and the arrow keys move to the next cell. Add and remove rows and columns with the Row and Column menus, or by right-clicking a cell. You can also import an Excel workbook or a CSV file with File / Import CSV or Excel file.
  2. Format it. Select cells by clicking them, by dragging over them or with Shift and the arrow keys (Ctrl+click adds a cell), then align their text or make it bold or italic with the toolbar. Markdown syntax typed in a cell, such as **bold**, `code` or [a link](https://example.com), goes into the table as it is (only a | is escaped).
  3. Copy the code. The table's Markdown appears under the editor as you edit: click Copy to clipboard and paste it into your README, wiki or post. Preview shows how it renders.

Markdown tables

The original Markdown has no tables, but most Markdown today does: the generator writes the table syntax of GitHub Flavored Markdown (GFM), which GitHub, GitLab, Reddit, Obsidian, Jupyter and many other Markdown processors read. Its first row is the header, followed by a line of dashes, in which colons set the alignment of each column:

| Tables   |      Are      |  Cool |
|----------|:-------------:|------:|
| col 1 is |  left-aligned | $1600 |
| col 2 is |    centered   |   $12 |
| col 3 is | right-aligned |    $1 |

A column is aligned like its cell in the first row. Markdown tables cannot merge cells or hold several lines of text in a cell: line breaks in a cell become spaces, or <br> with Line breaks as <br> (which GFM renders). Compact mode leaves out the spaces that line up the columns.

For the syntax in depth, the mistakes that break a table and tables in Discord and Slack, see our guide How to make a table in Markdown.

Convert Excel, CSV or HTML to Markdown

Select the cells in Excel, Google Sheets or LibreOffice Calc and copy them. Click the top left cell of the editor and press Ctrl+V. The Markdown code appears under the editor. The cells keep their alignment, and a column is aligned like its cell in the first row. A table copied from Word, Google Docs or a web page pastes the same way. For a file, select File / Import CSV or Excel file: it reads .csv files and Excel workbooks (.xlsx).

To convert HTML code of a table, select File / Paste table data, paste the code in the box and click Load. Merged cells are split, because Markdown has none.

Convert Markdown to a table, Excel or CSV

Select File / Paste table data, paste the Markdown code and click Load. The cells come in the editor with the alignment of the columns, and you can change them there. Then:

  • To Excel or Google Sheets: click a cell, press Ctrl+A to select all cells and Ctrl+C to copy them, and paste them in the spreadsheet.
  • To a CSV file: select File / Download as CSV.
  • To HTML, LaTeX or a text table: open the HTML, LaTeX or text tables generator in the same browser tab. The table is there, and the code under it is in that format.

Tables in GitHub README files

GitHub shows Markdown tables in README files, issues, pull requests, comments and wikis. Paste the code on a line of its own, with an empty line before and after it. Three things to know:

  • A table wider than the page scrolls sideways. It does not wrap to the width of the page.
  • For merged cells, write the table in HTML, which GitHub shows too: make it in our HTML Tables Generator. GitHub removes its colours and other styles.
  • For a line break in a cell, check Line breaks as <br>.

GitLab, Bitbucket, Gitea and Azure DevOps read the same tables.

Tables in Reddit, Discord and Slack

Reddit shows Markdown tables. In its editor, switch to Markdown mode and paste the code. Discord, Slack, WhatsApp and Telegram show no tables: the code shows as lines with | signs. Send a text table in a code block instead. Make it in our Text Tables Generator and put ``` on the lines before and after it.

Why does my table not show as a table?

  • The line of dashes under the header is missing, or it has another number of cells than the header row.
  • There is no empty line before the table. GitHub does not need it, but many other programs do.
  • A cell has a | that is not written as \|. The generator escapes it for you.
  • The lines start with four spaces or a tab: the table then shows as code.

The Markdown tables guide lists more causes, with their fixes.