Why a URL beats sending the file
An .html file sent as an attachment rarely arrives as a page. Gmail and Outlook show a download prompt or the raw code, phones open it in a text viewer, Slack and Teams preview it as source, and many company mail filters strip it entirely because HTML attachments are a common phishing trick. A URL avoids every one of those problems: the person taps it and the browser renders the page, exactly as you saw it.
Upload the file — or the folder it lives in
- Single, self-contained file (all CSS and JS inside it, images from the web or embedded): drop just the
.htmlfile. - File that uses other files (
style.css,script.js, animages/folder): choose choose a folder, or zip the folder and drop the ZIP. Every relative path keeps working. - Several pages (
index.html,about.html…): upload the folder; the file namedindex.htmlbecomes the home page and the others are served at their own paths.
Not sure which you have? Open the file in the HTML viewer: if pictures or styling are missing there, the file depends on other files and you should upload the folder.
.html vs .htm vs .xhtml
All three are web pages and all three upload. .htm is the same format with the three-letter extension older Windows tools used; it is served identically. If your only file is named something other than index.html, it still becomes the home page of your URL.
Uploading from a phone
On Android, tap Upload then the drop area and pick the file from Downloads or Files. On iPhone, the file picker opens the Files app — the file is usually in Downloads or On My iPhone. If the file arrived as an email or WhatsApp attachment, save it to Files first. More detail in how to open an HTML file on a phone.
Common problems after uploading
- Images show as broken icons — the paths point to
C:\Users\…or a folder you did not upload. Use relative paths and upload the folder. - Styles missing on some pages — file names are case-sensitive online:
Style.cssandstyle.cssare different files on most servers. (We match case-insensitively as a safety net, but fix it at the source.) - Fonts or videos blocked — links starting with
http://are blocked on HTTPS pages. Change them tohttps://.