File format · .html
A web page in one file.
Import an .html file, an exported page or an email you saved, and Docs keeps its structure and cleans out everything else. Download any document as a single, self-contained web page: styles and pictures inside, and nothing loaded from anywhere when it opens.
A web page opens in any browser on any device, with no app to install. It's a good way to hand over a document with its pictures in one file, to publish it on a site, or to keep an archive copy that will always open.
Bring it in
Import HTML files
From your library
Choose Import a file, or drag files onto your documents. Each file becomes a new document, named after the file.Into an open document
In a document, File › Import file… adds the file at your cursor, or replaces what's there.Check the result
Docs keeps text, headings, lists, tables, links and embedded pictures, and drops scripts, frames and anything else that doesn't belong in a document.
What comes across
- Headings, paragraphs, emphasis and links
- Lists, tables and quotes
- Pictures embedded in the file, encrypted as they're added
- Basic text styling from an allowed list
Good to know
- Files up to 50 MB, ending .html, .htm or .xhtml.
- Scripts, styles, frames and embedded objects are removed, and anything else not on Docs's allowed list is reduced to its text.
- Pictures that point to the web are never fetched: a link to each is kept instead.
Take it out
Download as a web page
Choose File › Download › Web page
The page is built on your computer, with every tab or only the open one.Open, send or publish it
It opens in any browser. Attach it, host it, or keep it as an archive copy.
What the file keeps
- The document's look: headings, fonts, colours, tables and lists
- Pictures, decrypted on your computer and placed inside the file
- Links, quotes and code blocks
- Everything in one file, with no separate folder of images
Good to know
- The page blocks every network request, so opening it never contacts anyone, not even us.
- Comments are left out; suggestions still pending show as marked, as they do on screen.
- Pictures inside the file make it larger; a document with many photos makes a big page.
Converted on your computer
Questions
Questions about HTML files
Is it safe to import HTML from somewhere else?
Docs treats imported files as untrusted. The HTML is reduced to a list of allowed elements, attributes and styles before it becomes a document, and nothing in it is fetched from the web.
Does the exported page load anything from the internet?
No. Styles and pictures are inside the file, and the page includes a rule that forbids network requests, so opening it never contacts anyone.
Can I paste the page into my website?
Yes. It's standard HTML with inline styles. Copy the parts you need into your site, or host the file as it is.
Write it together. Keep it yours.
Documents are end-to-end encrypted, so only you and the people you invite can read them.