HOSTING

Share a Word document as a web page

A .docx attachment has to be downloaded and opened in Word, and on a phone it often renders badly. Convert it to one HTML file with the images inside, upload it, and send a link that opens in any browser.

4 min read·

A Word file sent as an attachment lands in the reader's downloads folder, needs Word or a viewer app, and every revision means a new attachment. A web page opens in the browser on any device, and the link stays the same when you revise the document.

Convert the .docx to HTML

  • ✓Install mammoth, an open-source converter: pip install mammoth (there is also a JavaScript version on npm with the same name).
  • ✓Run mammoth report.docx report.html. Headings, bold and italic text, lists, tables and links come through as plain HTML. Tested on mammoth 1.13.0.
  • ✓Images are written into the file as base64 data URIs, so the output is a single self-contained file. Use --output-dir only if you want the images as separate files.
  • ✓mammoth maps Word styles to HTML on purpose and drops exact fonts, colours and page layout. Use Word's built-in Heading styles rather than manually enlarged text so headings convert as headings.

Wrap it in a page

  • ✓mammoth outputs the body content only, with no <html>, <head> or charset line. Without a charset, quotes and accented letters can show up garbled.
  • ✓Put <!doctype html><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>Your title</title> at the top of the file, before the converted content.
  • ✓Add a short <style> block for readability: body { max-width: 720px; margin: 2rem auto; padding: 0 1rem; font-family: system-ui, sans-serif; line-height: 1.6 } img { max-width: 100% } table { border-collapse: collapse } td, th { border: 1px solid #ccc; padding: 4px 8px }.

Upload it and send the link

Drag the HTML file onto the FileShare Pro dashboard and copy the link. Readers need no account and no Word. Shared pages carry a noindex tag, so a draft does not show up in search. On Pro you can add a password: password-protecting an HTML page.

Turn on comments and readers can leave a note on the page after typing a name, so review feedback stays next to the text instead of in a chain of tracked-changes attachments. The view count shows whether the person you sent it to has opened it.

Need the exact Word layout, page breaks and fonts instead? Export to PDF and share that: sharing a PDF as a link. Writing in Markdown already? Sharing a Markdown file as a web page.

Update the document without a new link

Edit in Word, convert again and upload the new HTML over the old file. The link stays the same and the previous version is kept in history: updating a shared link without changing it.

Frequently asked

How do I share a Word document as a web page?

Convert the .docx with mammoth report.docx report.html, add a doctype and charset line at the top, upload the file to FileShare Pro and send the link. It opens in any browser.

Do the images come through?

Yes. mammoth embeds images in the HTML as base64 data, so the single file carries them and nothing else needs uploading.

Will it look exactly like Word?

No. Structure carries over: headings, lists, tables, bold, links and images. Fonts, colours and page layout do not. Share a PDF when the exact layout matters.

Can readers edit the document?

No. The shared page is read-only. Readers can leave comments if you turn them on.

Is it free?

Yes. The free plan hosts up to 50 files of up to 100 MB each, with view counts and comments included. Password-protected links are on Pro.

Got a page to share?

Drop the file, copy the link — live in seconds, free plan included.

Start sharing free