Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Ordinary GitHub Flavored Markdown (GFM) pipe tables cannot represent merged cells: they do not support HTML table attributes such as colspan or rowspan. If a converter turns an HTML table with spans into a pipe table, the output cannot preserve the same cell-spanning structure. Keep the table as HTML, flatten it into a rectangular grid, or use prose or lists when those options communicate the relationships more clearly.

Why merged cells break in Markdown tables

An HTML table can use colspan to make a cell cover multiple columns and rowspan to make it cover multiple rows. GFM pipe-table syntax has a fixed header and delimiter structure, but no syntax for either kind of span. MDN’s Markdown guidance explicitly says GFM does not support table attributes such as colspan, rowspan, or scope (MDN, “How to write in Markdown”).

That means a converter may read an HTML table successfully yet still be unable to encode its merged-cell layout in GFM. The result can have rows that no longer correspond cleanly to the source table’s logical columns. Under the GFM specification, missing cells in a data row are treated as empty, while excess cells are ignored. Depending on how a converter emits a row, information can appear missing or misaligned.

Choose a workaround based on the destination

Approach When it fits Trade-off
Keep the table as HTML The destination accepts and preserves raw HTML tables. Retains spans, but renderer support must be confirmed.
Expand into a rectangular pipe table Markdown pipe-table output is required and repeating values remains clear. Repeating labels or values preserves the grid’s meaning, but not native merged-cell formatting.
Use prose or lists Repeating values would make irregular relationships difficult to understand. May be clearer to read, though it is no longer a compact table.

Keep the HTML when the renderer supports it

MDN recommends HTML when a GFM table needs unsupported features. Preserve the original <table> markup, including its span attributes, if the destination renderer allows raw HTML and keeps those attributes. Test the rendered result: some destinations may strip or alter HTML, so retaining it in the source alone does not guarantee that readers will see the merged cells.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Flatten spans when pipe-table output is mandatory

Represent the source as a regular rectangular grid by repeating the spanning label or value in every logical cell it covers. This is a workaround, not native merging. Check each resulting row against the original so repeated entries neither shift into the wrong columns nor omit information.

Switch to prose or lists for irregular relationships

If repetition makes the table confusing, explain the grouped relationship in prose or a list instead. This can be more readable than forcing a complex or irregular table into a fixed-width pipe grid.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Convert HTML, then check what survived

Pandoc documents this general conversion command in its User’s Guide:

pandoc -f html -t markdown hello.html

The command converts HTML input to Markdown output; it does not guarantee that merged-cell semantics survive in the selected Markdown flavor. Review the generated table against the source and check how the destination renderer handles the chosen output. If the spans matter and pipe-table Markdown cannot preserve them, use HTML where supported or choose a representation that makes the relationships explicit.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.