Skip to main content
Premier SEO Services

Developer tools

Word to HTML Converter

Paste formatted text from Word, Google Docs or a web page, or open a .docx file, and get clean HTML: headings, lists, tables, links, bold and italic kept, fonts, colors and Office markup removed.

  • Runs in your browser
  • Free, no sign-up
  • Unlimited use
  • Updated 30 September 2026

Word to HTML Converter

Paste your text — the result updates as you type

  • Only .docx files can be opened; save older .doc files as .docx first.
  • Images pasted from Word point to files on your computer and are left out; open the .docx to keep images.

How to use the word to HTML converter

  1. 1Under Source, keep Paste formatted text, click the dashed box and press Ctrl + V (⌘V on a Mac). Or choose Open a .docx file and pick the document.
  2. 2Choose what to keep: Keep tables, Keep images (embedded as data URIs) and Replace   with spaces.
  3. 3Check the result under Clean HTML; switch Show to Preview to see it rendered. The footer shows how much markup was removed.
  4. 4Press Copy and paste into your CMS's HTML or code view, or Download document.html.

Example

Input
<h1 style="mso-margin-top-alt:auto"><span style="font-family:Calibri">Quarterly report</span></h1>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:Calibri">Sales rose <b>12%</b> in <i>Q3</i>.<o:p></o:p></span></p>
<p class="MsoListParagraphCxSpFirst" style="mso-list:l0 level1 lfo1"><![if !supportLists]><span style="mso-list:Ignore">·<span>&nbsp;&nbsp;</span></span><![endif]>New stores</p>
<p class="MsoListParagraphCxSpLast" style="mso-list:l0 level1 lfo1"><![if !supportLists]><span style="mso-list:Ignore">·<span>&nbsp;&nbsp;</span></span><![endif]>Online growth</p>
Output
<h1>Quarterly report</h1>
<p>Sales rose <strong>12%</strong> in <em>Q3</em>.</p>
<ul>
  <li>New stores</li>
  <li>Online growth</li>
</ul>

Shortened clipboard HTML from Word. Word writes bullet lists as styled paragraphs with a fake bullet character; the converter rebuilds them as a real <ul>.

Pasting from Word or Google Docs

When you copy from Word, Google Docs, Pages or a web page, the clipboard holds HTML as well as plain text. The paste box reads that HTML directly, so the structure survives: headings stay headings and lists stay lists. If the clipboard has no HTML (text copied from Notepad, for example), the text is converted into paragraphs instead.

The box accepts pastes only; typing into it is ignored, because the point is to convert existing formatted content. To write HTML by hand, use the HTML viewer.

What gets cleaned

Word's clipboard HTML is often ten times the size of the content. The converter removes:

  • style attributes (fonts, sizes, colors, margins, mso- properties) and class names such as MsoNormal
  • <span> and <font> wrappers, Office XML (<o:p>, <w:…>), conditional comments and <style> blocks
  • empty paragraphs, non-breaking spaces used for spacing (optional) and javascript: or file: links

Formatting that carries meaning is converted to semantic tags: bold to <strong>, italic to <em>. Google Docs marks bold and italic with font-weight and font-style styles on spans rather than tags, and those are converted too.

Kept: <h1>–<h6>, paragraphs, bulleted and numbered lists (including Word's fake lists, rebuilt as <ul> or <ol> from their bullet or number), <blockquote>, <pre>, links with their href, <sub>, <sup> and line breaks. Tables keep their rows, header cells and colspan/rowspan, but lose borders and widths; untick Keep tables to turn each row into a paragraph instead.

When you open a .docx, the Mammoth library converts it using Word's paragraph styles, so use real Heading 1/Heading 2 styles in Word rather than large bold text if you want <h1>/<h2> in the output. Images in a .docx are embedded as Base64 data URIs.

Using the HTML in a CMS

Paste the result into the HTML, Code or Text view of your editor (WordPress: Code editor or a Custom HTML block; Shopify and most others have a <> button). Pasting into the visual view would treat the tags as text. Because all inline styles are gone, the content picks up your site's own fonts and spacing, which is usually what you want.

Data-URI images make the HTML very large and are poor for page speed; upload the images to your media library and replace the src values. Run the result through the HTML formatter if you want it indented for editing.

Is my text private?

This tool runs entirely in your browser. Your text is not uploaded to our servers.

Sources

Questions about the word to HTML converter

Why does Word HTML contain so much junk?

Word exports HTML that can be reopened in Word without losing anything, so it stores every font, margin and list setting as Office-specific markup. Web pages need none of it.

Are images converted?

From a .docx file, yes: they are embedded as data URIs. Images in pasted content usually point to temporary files on your computer, so they are left out and the footer counts them.

Can I keep tables?

Yes, with Keep tables ticked: rows, cells, header cells and merged cells are kept as plain HTML tables without Word's borders and widths.

Last updated 30 September 2026Maintained by Premier SEO Services

Report a problem