Skip to content
TextArray
100% local

HTML table to Markdown

Convert HTML tables to GitHub-flavored Markdown tables with alignment kept.

Input
Output

HTML table to Markdown

Paste HTML that contains a table and get a GitHub-flavored Markdown table back — pipe-separated cells, a separator row and columns padded to equal width so the source stays as readable as the render. Typical jobs: moving documentation into a GitHub or GitLab wiki, adding a table to a README, converting a table copied from a CMS or an Excel-exported page, or migrating legacy HTML docs to Markdown.

The converter finds every table element in the input and converts them all, separated by blank lines, so you can paste a whole page rather than cutting out fragments. Wrappers like thead, tbody and tfoot are read transparently. When the first row uses th cells, it becomes the Markdown header; otherwise the "First row is headers" option decides — switch it off and the tool emits an empty header row, because a Markdown table cannot exist without one. Alignment set with align attributes or a text-align style on the header cells is carried over as :---, :---: and ---: markers.

Cell content is cleaned on the way through: inner tags are stripped while their text is kept, br becomes a space, common and numeric HTML entities are decoded, whitespace collapses to single spaces and pipes are escaped so data can never add a column. Since Markdown has no cell spanning, a colspan repeats its text across the columns it covers and rows under a rowspan get empty cells. Compact output skips the padding when you want the smallest possible source.

The conversion runs entirely in your browser — the HTML never leaves your device, so internal documents are safe to convert. Copy the result or download it as a .txt file.

FAQ

How are colspan and rowspan handled?
Markdown has no cell spanning. A colspan cell repeats its text across all the columns it covers, and cells hidden by a rowspan come out as empty cells in the following rows, so the grid stays rectangular.
What if my table has no th header row?
With "First row is headers" on, the first row becomes the header. Switch it off and the tool emits an empty header row instead — Markdown tables require a header, so leaving it out would produce invalid Markdown.
Does the alignment survive the conversion?
Yes. align="center" or a text-align style on the header cells becomes the :---:, ---: or :--- separator markers that GitHub, GitLab and most renderers understand.
Can it convert more than one table at once?
Yes. Every table element in the input is converted, in order, separated by a blank line — pasting a whole HTML page works.
Is my HTML uploaded anywhere?
No. The conversion runs entirely in your browser and your HTML never leaves your device.