Boneyard Tools

CSV to HTML Table Converter

Paste CSV to get a ready-to-paste HTML table. Quoted fields, commas inside quotes and special characters are handled and escaped, with options for a header row, a table class and minified output.

How to convert CSV to an HTML table

  1. Paste your CSV data into the box.
  2. Choose whether the first row is a header, set an optional table class, and pick pretty or minified output.
  3. Copy the generated HTML table.

Examples

Simple table

Name,Role
Ada,Engineer
Linus,Maintainer
<table>
  <thead>
    <tr>
      <th>Name</th>
      <th>Role</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>Ada</td>
      <td>Engineer</td>
    </tr>
    <tr>
      <td>Linus</td>
      <td>Maintainer</td>
    </tr>
  </tbody>
</table>

Frequently asked questions

Does it handle commas inside quoted fields?

Yes. A field wrapped in double quotes can contain commas, line breaks and escaped quotes (written as two double quotes), and it is parsed as a single cell.

Is the HTML safe to paste anywhere?

Yes. Cell values are HTML-escaped, so characters like <, >, & and quotes become entities and cannot break your markup or inject elements.

What happens to line breaks inside a cell?

A hard line break inside a quoted field is converted to a <br> tag so multiline cells render on separate lines in the table.

What if my CSV has no header row?

Turn off the header option and every row is rendered as a <tbody> row of <td> cells, with no <thead> section.

Can I add a CSS class to the table?

Yes. Enter a class name and it is added to the <table> element as a class attribute so you can style it with your own CSS.

Is my data private?

Yes. The conversion runs entirely in your browser and nothing is uploaded.

Related tools