How to share an HTML file so it actually opens

Sent someone an .html file and they saw a wall of code, or couldn't open it at all? That's normal on phones. The fix is to share a link to the page instead of the file.

Try it now: free, no sign-upUpload an HTML page or PDF and get a link + QR code in seconds.
Create a free link

How to do it

  1. Go to DropMyPage and upload your .html file (or paste the code).
  2. Tap Create link.
  3. Send the link. It opens as a normal web page on any phone, tablet or computer.

Why HTML attachments don't work well

Your options compared

MethodOpens on phones?Setup
Send the .html as an attachmentOften notNone
Host it on a web serverYesAccount, upload, domain
Share it as a DropMyPage linkYesNone, about 30 seconds

Tip: keep it in one file

If your page uses separate CSS or JS files, paste their contents into <style> and <script> tags in the HTML before uploading. Then everything travels together.

Questions

Can I share an HTML file on WhatsApp?

You can attach it, but most people won't be able to view it. Share a link instead: DropMyPage has a one-tap WhatsApp button. See how to share HTML on WhatsApp.

Is my page public?

Only people with the link can open it. It isn't listed anywhere or shown on Google.

Can I delete it later?

Yes, with the private manage link you get when you create it. Free links also delete themselves after 7 days.

Ready?It takes about 30 seconds.
Create a free link

Related guides