ExcelTool.io

Excel to HTML Converter

Turn worksheet data into clean HTML table markup. Copy the table for docs, CMS pages, email drafts, or lightweight reports.

Drop your file here or click to upload

Supports .xlsx, .xls, .xlsm, .xlsb · up to 50MB · or paste a file from your clipboard

How to Convert Excel to HTML

  1. Upload your workbook - .xlsx, .xls, .xlsm and .xlsb are all read.
  2. Select a worksheet - Multi-sheet workbooks get a Sheet dropdown; one sheet is exported at a time.
  3. Set the two options - Decide whether the first row becomes <th> cells and whether the sheet name is added as a <caption>.
  4. Copy or download - Copy the markup to the clipboard, or save it as a .html file.

What the exporter writes

The output is deliberately plain: a <table>, an optional <caption> holding the worksheet name, and one <tr> per row with two-space indentation. There are no attributes on any element - no class, no style, no colspan, no inline widths - so the table inherits whatever CSS the page it lands in already has.

<table>
  <caption>Q1 Sales</caption>
  <tr><th>Region</th><th>Revenue</th></tr>
  <tr><td>North</td><td>42000</td></tr>
  <tr><td>South</td><td>36500</td></tr>
</table>

With First row as headers on, row 1 is written with <th> cells and every other row with <td>. Turn it off and every row uses <td>. The preview above the output mirrors that choice, so what you see is what gets copied.

Escaping, and what it protects you from

Five characters are escaped in every cell and in the caption: & becomes &amp;, < and > become &lt; and &gt;, and both quote characters become &quot; and &#39;. That matters because worksheet cells hold arbitrary text: a cell containing <script> markup is published as visible text rather than as running script, and a product name containing < does not silently swallow the rest of the row. Accented and non-Latin characters are left as themselves rather than turned into entities, so the markup stays readable as long as the page it goes into is served as UTF-8.

What the values look like

  • Numbers - written as the stored value, with floating-point noise trimmed to twelve significant digits so a subtraction that Excel shows as 57.81 is not published as 57.809999999999945.
  • Dates and times - written as their underlying serial numbers. A cell displaying 15/03/2023 exports as 45000.
  • Currency and percentages - the number without its format, so $1,234.50 becomes 1234.5 and 15% becomes 0.15.
  • Formulas - the cached result, not the formula text.
  • Booleans - true and false.
  • Errors - #N/A, #DIV/0! and the rest export as empty cells.

Edge cases

  • Merged cells are flattened. The top-left cell of a merged range keeps the value; the cells it covered export empty. No colspan or rowspan is generated.
  • Blank leading rows and columns are kept.The export covers the sheet's used range, so a report that starts at C5 exports with the empty rows and columns in front of it. Delete them in the workbook first if you do not want them in the markup.
  • Hidden rows and columns still export. Hiding a column in Excel does not remove it from the data, and this exporter writes the data.
  • Cell formatting does not cross. Fonts, fills, borders, alignment, conditional formatting, column widths and images are not represented in the output at all.
  • Line breaks inside a cell stay as newline characters in the markup, which HTML collapses to a single space when it renders. Add a <br> yourself if you need the break to show.
  • The file is a fragment. The .html download is the table only. Paste it into a page, template or CMS field that already provides the document around it.

When to use a different tool

Frequently Asked Questions

Related Tools