HTML Table to CSV Converter
Paste HTML <table> markup and get clean, RFC-4180 CSV — runs entirely in your browser.
Preview
| Name | Role | City |
| Ada Lovelace | Engineer | London |
| Grace Hopper | Admiral | New York |
| Turing, Alan | Researcher | Cambridge |
How HTML table to CSV conversion works
The converter scans your markup for the first <table> element using a lightweight regex tokenizer — no browser DOM parser is used, so it works the same on every device. It walks each <tr> row in document order and reads cell text from both <th> and <td> tags, stripping inline markup like <span> or <br> and decoding common HTML entities (&, , and friends).
Output follows RFC 4180: any field containing the chosen delimiter, a double quote, or a line break is wrapped in quotes with internal quotes doubled (for example Turing, Alan becomes "Turing, Alan"). Rows with a different number of cells than the widest row are padded with empty fields so every line has the same column count. Choose comma, semicolon, tab, or pipe as the delimiter to match the spreadsheet or database tool you're importing into.
Everything happens locally in your browser — nothing you paste is ever uploaded. For the reverse conversion, see CSV to HTML Table Converter. To turn a table into structured JSON instead, try HTML Table to JSON.
Private & free — this tool runs entirely in your browser.