Guide

How to send an HTML file by email

You can attach an HTML file, since Gmail and Outlook do not block the .html extension, but it is a poor way to deliver one. Some corporate filters flag or quarantine .html attachments because they are a common phishing vector, and even when one gets through, the recipient sees a download prompt instead of a rendered page. The fix is to turn the file into a link first (LiveSend, or any host built for one-off HTML) and paste that link into the email body. The email still does the sending, the link does the displaying.

Why "just attach it" does not work

HTML is the one common file type that looks like an attachment but behaves like a security risk. An .html file can contain a form that posts credentials somewhere, a script that redirects on open, or a pixel-perfect copy of a login page, so corporate mail gateways often treat it with suspicion. Gmail and Outlook themselves let .html attachments through, but a recipient behind a corporate gateway may find the file flagged, stripped or quarantined, and none of that is visible or configurable from the sending side.

The actual path: link first, then email

Three steps, and the only one that changes anything is the first:

  1. Drop the .html file into LiveSend (drag-and-drop or paste the source) and copy the URL it returns.
  2. Write your email as normal.
  3. Paste the link into the body instead of attaching the file.

The recipient clicks a normal-looking link, gets a rendered page in their browser, and nothing was ever attached for a filter to inspect or block. Each view is logged, so you can also tell whether it was opened.

What still does not work

  • Renaming the extension (.html to .txt, for example) breaks the file for the recipient without reliably fooling the filter, which usually inspects content, not just the extension.
  • Zipping the file sometimes passes the filter, but shifts the burden to the recipient (extract, then open an unfamiliar file), which is worse for open rates than a link.
  • Pasting the raw HTML as text in the email body gets sanitized or mangled by every major email client. It never renders as intended.

The short version

Do not attach the .html file. Host it (LiveSend takes under a minute for a one-off file), and send the link instead. It is the only path that reliably reaches the recipient as a working page rather than a flagged, downloaded or broken attachment.

Not sure which host to use? See the shortest path from .html file to link.

Frequently asked questions

  • Do email providers block .html attachments?
    Not Gmail or Outlook: both publish a list of blocked file types, mostly executables and scripts such as .exe, .js and .vbs, and .html is not on it. But an .html file can contain a form, a script, or a page that looks exactly like a bank or login screen, so it is a favorite tool for phishing, and many corporate mail filters flag, strip or quarantine it with rules you cannot see from the sender side.
  • What happens if the attachment does get through?
    The recipient sees a download prompt, not a rendered page. Double-clicking it opens the file in a browser as a local file, where any assets referenced by relative URL (images, fonts, a script hosted elsewhere) are likely to be missing, because there is no server behind a local file. Interactive elements that depend on JavaScript running in a real page context can also misbehave.
  • Can I zip the file to get around a filter?
    Some filters catch .html inside a .zip too, and the ones that do not just move the problem: the recipient now has to extract an archive and double-click an unfamiliar file, which is exactly the behavior security-conscious recipients and IT departments are trained to avoid. It rarely improves delivery.
  • What is the actual fix?
    Turn the file into a URL before you write the email. Drop the .html into LiveSend (or Tiiny.host, or Netlify Drop) and get a link back in under a minute. Paste that link into the email body like any other URL. It passes every spam filter because it looks like normal text, and the recipient gets a rendered page in their browser instead of a download prompt.
  • Does the link still work if I need to update the file later?
    On LiveSend, yes: edit the document inline or upload a new version and the link stays identical, so you never have to resend a corrected email. Re-hosting the same file elsewhere usually produces a new URL, which means a new email.

Related guides

Want to try the LiveSend approach?

Paste your HTML, get a permanent link. Free for the first 3 documents.

Get started free