Learn how to create tables in markdown with alignment, formatting, and multi-line content. Syntax, examples, and platform support.
Markdown tables use pipes (|) and hyphens (-) to create rows and columns. The second row defines column alignment with colons. Tables are ideal for structured data, comparisons, and reference material.
A simple table with headers and two data rows.
| Header 1 | Header 2 | Header 3 |
|---|---|---|
| Cell 1 | Cell 2 | Cell 3 |
| Cell 4 | Cell 5 | Cell 6 |
Use colons in the separator row to align columns left, center, or right.
| Left | Center | Right |
|---|---|---|
| aligned | aligned | aligned |
You can use inline formatting (bold, italic, code, strikethrough) inside table cells.
| Feature | Status |
|---|---|
| Bold | code |
| Italic |
| Platform | Supported | Notes |
|---|---|---|
| GitHub | Yes | Full GFM table support |
| GitLab | Yes | — |
| Discord | No | No table support — use code blocks instead |
| Slack | No | No table support |
| Yes | — | |
| Stack Overflow | Yes | — |
| Notion | Yes | Paste markdown tables or use slash command |
| Obsidian | Yes | — |
| Header 1 | Header 2 | | Cell 1 | Cell 2 |
| Header 1 | Header 2 | | -------- | -------- | | Cell 1 | Cell 2 |
The separator row (with hyphens) is required. Without it, the table won't render.
| Header 1 | Header 2 | | --- | | Cell 1 | Cell 2 |
| Header 1 | Header 2 | | --- | --- | | Cell 1 | Cell 2 |
The separator row must have the same number of columns as the header row.
| Header | |--------| | Cell with | pipe |
| Header | |--------| | Cell with \| pipe |
Escape pipes inside cells with a backslash (\|), otherwise they'll be interpreted as column separators.
Writing tables by hand is tedious. Use our table generator tool to build them visually and copy the markdown.
Use :--- for left, :---: for center, and ---: for right alignment. Default is left-aligned.
| :--- | :---: | ---: |
Markdown tables don't support merged cells, multi-line cells, or nested tables. For complex layouts, consider HTML tables.
You don't need to align the pipes perfectly — the table renders the same either way. But aligned pipes are easier to read in source.
Everything you need to know.
Use pipes (|) to separate columns and hyphens (-) for the separator row between headers and data. Example: | Name | Age |\n| --- | --- |\n| Alice | 30 |
Markdown supports two types of code formatting: inline code with single backticks (`) for short snippets, and fenced code blocks with triple backticks (```) for multi-line code with optional syntax highlighting.
Links in markdown use square brackets for the display text and parentheses for the URL: [text](url). You can also add hover titles, use reference-style links for cleaner source, and auto-link bare URLs on most platforms.
Bold text in markdown is created by wrapping words with double asterisks (**) or double underscores (__). Bold draws attention to important words and phrases, making your content easier to scan.
Paste your markdown and see table rendered instantly with professional themes.