Blog
Wild & Free Tools

Convert HTML Tables to Markdown Online

Last updated: February 2026 5 min read
Quick Answer

Table of Contents

  1. HTML Table vs Markdown Table
  2. How to Convert
  3. GFM Table Syntax Explained
  4. Where GFM Tables Work
  5. Limitations
  6. Frequently Asked Questions

HTML tables are verbose — dozens of <tr>, <td>, and <th> tags to represent what is essentially a grid of data. GitHub Flavored Markdown (GFM) table syntax is far more compact and readable, and it works in GitHub, GitLab, Obsidian, Notion, and most modern Markdown editors.

The converter handles the translation automatically — paste the HTML, get GFM table syntax back.

HTML Table Syntax vs. Markdown Table Syntax

A simple three-column HTML table:

<table>
  <thead>
    <tr>
      <th>Name</th>
      <th>Price</th>
      <th>In Stock</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>Widget A</td>
      <td>$12.99</td>
      <td>Yes</td>
    </tr>
  </tbody>
</table>

The same table in GFM Markdown:

| Name | Price | In Stock |
| --- | --- | --- |
| Widget A | $12.99 | Yes |

The Markdown version is 80% shorter, human-readable without any rendering, and editable in any text editor without worrying about closing tags. Converting from HTML to Markdown is a one-way simplification — you lose nothing in the table data, only the verbose tag structure.

How to Convert an HTML Table to Markdown

  1. Get the HTML table. Copy it from the page source, Inspect element, or wherever the table lives. You can paste the full page HTML — the converter handles tables anywhere in the document.
  2. Paste into the converter input area.
  3. Click "Convert to Markdown."
  4. Find your table in the output. If you pasted a full page, the table appears in context with the surrounding content. If you pasted just the <table> element, the entire output is the GFM table.
  5. Copy the Markdown table and paste it into your destination.

The converter handles <thead>, <tbody>, <th>, and <td> elements. Header rows become the top row with the separator line below (| --- | --- |). Body rows become data rows.

Sell Custom Apparel — We Handle Printing & Free Shipping

GitHub Flavored Markdown Table Syntax Explained

GFM table syntax uses pipes (|) to separate columns and hyphens for the separator row between headers and data:

| Header 1 | Header 2 | Header 3 |
| --- | --- | --- |
| Row 1, Col 1 | Row 1, Col 2 | Row 1, Col 3 |
| Row 2, Col 1 | Row 2, Col 2 | Row 2, Col 3 |

Alignment — You can align columns by adding colons in the separator row:

| Left | Center | Right |
| :--- | :---: | ---: |
| data | data | data |

Cell content — Cells can contain basic Markdown formatting: bold, italic, inline code, and links. They cannot contain multiple paragraphs, images, or block-level elements.

Edge case — Pipe characters (|) inside table cells need to be escaped as \| or the Markdown parser will treat them as a column separator. The converter handles this automatically for HTML tables that contain | in cell content.

Where GFM Markdown Tables Are Supported

GFM table syntax is widely supported across Markdown environments:

Where GFM tables are NOT supported: standard CommonMark without GFM extensions does not include tables. Some minimal Markdown processors or older systems may render the table as literal pipe-separated text rather than a visual table.

HTML Table Features That Do Not Convert to Markdown

GFM table syntax is intentionally simple. Several HTML table features have no Markdown equivalent:

For simple data tables — the most common case — conversion is clean and complete. For complex layout tables or tables with merged cells, manual cleanup after conversion is usually necessary.

Convert HTML Tables to Markdown

Paste any HTML. GFM table syntax out. Free, no signup, instant.

Open Free HTML to Markdown Converter

Frequently Asked Questions

How do I convert an HTML table to Markdown?

Paste the HTML containing the table into the converter and click Convert. The output includes the table in GitHub Flavored Markdown (GFM) pipe syntax.

Do HTML tables with headers convert correctly?

Yes. <thead> with <th> elements become the header row in GFM table syntax with the separator line below.

What if the table has merged cells (colspan/rowspan)?

Markdown has no equivalent for merged cells. The converter flattens them — content may be duplicated or cells left empty. Manual cleanup is needed for complex merged-cell tables.

Does the Markdown table work in Obsidian and Notion?

Yes. Both Obsidian and Notion support GFM table syntax. Pasting the converted Markdown renders a visual table.

Carlos Mendez
Carlos Mendez Photo Editing & Image Writer

Carlos has been a freelance photographer and photo editor for a decade, working with clients from local businesses to regional magazines.

More articles by Carlos →
Launch Your Own Clothing Brand — No Inventory, No Risk