# How To Open an HTML File Sent on WhatsApp (Android and iPhone)

Canonical: https://commareports.com/open-html-file-in-whatsapp
Published: 2026-11-25

> Someone sent you an .html file on WhatsApp and it won't open, shows code, or opens blank. Where WhatsApp saves it, which app renders it on Android and iPhone, why reports break on a phone, and the fix that works everywhere.

# Opening an HTML file someone sent you on WhatsApp

A colleague drops `report.html` into the chat. On a laptop it would open
in a browser. On a phone you get one of these:

- WhatsApp says it **can't open the file**, or nothing happens.
- It opens as **raw code** — tags, brackets, no page.
- It opens, but it's **blank** or completely unstyled.

WhatsApp doesn't render HTML itself. It hands the file to another app,
and what happens next depends on your phone and on what the file
actually is.

## On Android

1. **Tap the document** in the chat to download it, then tap it again.
2. Android asks which app to use. Pick **Chrome** or **Samsung
   Internet** — not a text editor, and not a bare "HTML Viewer", which
   shows simple markup and usually ignores scripts.
3. **No browser offered, or it opens straight into the wrong app?** Open
   your file manager (Files by Google, or My Files on Samsung) and go to
   the WhatsApp documents folder:
   - Android 11 and later: `Android › media › com.whatsapp › WhatsApp › Media › WhatsApp Documents`
   - Older Android: `WhatsApp › Media › WhatsApp Documents`

   Long-press the file → **Open with** → choose the browser.

4. If a wrong app keeps grabbing it, clear its default under
   _Settings → Apps → that app → Open by default_.

Full walkthrough, including the `content://` problem below:
[open an HTML file on Android](/open-html-file-on-android).

## On iPhone

1. **Tap the document.** WhatsApp shows it in its built-in document
   preview — the same Quick Look previewer the Files app uses. A simple
   page often renders right there.
2. For more room, tap **Share → Save to Files**, then open it from the
   **Files** app.

That's as far as it goes. iOS has no way to open a local `.html` file as
a normal Safari tab, so you're always in a previewer. Pages that rely on
scripts, separate files or data fetched at view time may stay partly or
completely blank. More detail: [open an HTML file on iPhone](/open-html-file-on-iphone).

## Or open it right here

Use the box on this page: pick the file you saved from WhatsApp, and it
renders in your browser. On Android, the file picker can reach the
WhatsApp Documents folder; on iPhone, save it to Files first. Nothing is
published unless you ask for a link.

## Why it opens blank: it was never one file

Most "HTML reports" are really a **folder**: `index.html` plus `css/`,
`js/`, images and data files. Playwright and Allure test reports, coverage
reports, Jupyter and Sphinx exports, and any page saved from a browser
with _Save page as_ (which writes a `_files` folder next to the `.html`)
all work this way. WhatsApp sends the one file you attached. Every
reference inside it now points at something that isn't on your phone.

A zip doesn't rescue it on a phone. Android opens local files through a
**`content://` handle** to one file, so the page can't load the files
next to it even after unzipping. The iPhone previewer shows one file at a
time. And reports that load their data with `fetch()` are blocked from
reading local files on any device.

Nothing you change on the phone fixes this. The page has to be at a web
address.

## The fix: ask for a link, not a file

Whoever has the report on a computer drags the file — or the whole
output folder, or a zip — into [Comma](https://commareports.com/) and
pastes the link into the chat instead:

- `index.html` becomes the page, the CSS, scripts, images and data upload
  alongside it, and relative references point at the uploaded copies.
- It opens in Chrome or Safari like any website, with charts and filters
  working. Nothing to download, save, or unzip.
- Everyone in the group opens the same page, and can comment on a
  specific number instead of sending screenshots back.

## If you're the one sending it

An `.html` attachment costs every recipient those steps on a phone and
often still fails. Send a link the first time. If it has to be a file,
the [HTML inliner](/tools/html-inliner) packs a folder into one
self-contained `.html` that at least opens offline.

## Is it safe to open?

Be careful with `.html` files you didn't expect. An HTML attachment is a
long-standing way to deliver a **fake sign-in page**: it opens on your
phone, looks exactly like your bank or email login, and sends whatever
you type to someone else. If a file arrives out of the blue, check with
the sender, and never enter a password into a page that came as an
attachment.

Comma renders uploaded HTML inside a sandboxed iframe with no access to
your session, cookies or storage. That limits what a page can do to you;
it is not a malware scanner.

## Try it

Comma is free — unlimited reports, unlimited commenters, unlimited
revision history.

**[Turn the file into a link →](https://commareports.com/)**

### Related

- [Open an HTML file sent on Telegram](/open-html-file-in-telegram) — Android, iPhone and Telegram Desktop
- [Open an HTML file on Android](/open-html-file-on-android) — Files app, Chrome, and `content://` URIs
- [Open an HTML file on iPhone](/open-html-file-on-iphone) · [on iPad](/open-html-file-on-ipad) · [on a Chromebook](/open-html-file-on-chromebook)
- [Someone sent me an HTML file](/open-html-file-online) — on a computer
- [HTML file shows code instead of the page](/fix/html-file-shows-code-instead-of-page) · [in Gmail](/fix/gmail-html-attachment-shows-code)
- [Slack won't preview an HTML file](/fix/slack-wont-preview-html-file)
- [Why the report lost its CSS](/html-report-broken-css)
- [HTML inliner](/tools/html-inliner) · [Mobile-friendly test](/tools/mobile-friendly-test)
