.html File Extension

Learn what a .html file is, which apps open HTML pages, how Poly supports them, and how to convert or share them safely.

File extension details for .html

Full Support
File typeHyperText Markup Language document
MIME type
EncodingText, normally Unicode UTF-8, containing HTML markup
Operating systemsWindows, macOS, Linux, iOS, Android
Opens withGoogle Chrome, Microsoft Edge, Mozilla Firefox, Safari, Visual Studio Code
Poly supportYes. Poly provides rich support for HTML documents.
Indexed by PolyYes. Poly indexes the full source for exact and semantic search.
Preview in PolyYes. HTML files open as rendered pages in Poly.
Poly agentYes. The Poly agent can read the source and reason about its text and structure.

What kind of file is an .html?

An .html file is a HyperText Markup Language document. Its text markup describes headings, paragraphs, links, images, forms, scripts, and other parts of a web page. The registered text/html MIME type commonly uses both .html and .htm. The two suffixes represent the same format.1

HTML has no unique magic bytes. A document can begin with <!doctype html>, whitespace, a comment, or other permitted content. Inspect the source and supplied MIME type if the filename is misleading.1

Renaming page.htm to page.html changes only the filename. Renaming a PDF, image, or unrelated text file to .html does not convert it into a web page.

How do I open an .html on my computer?

Double-click an HTML file to open it in your default browser. Chrome, Edge, Firefox, and Safari can render local HTML on Windows, macOS, and Linux. Mobile browsers can display it too. Use a source editor such as Visual Studio Code when you need to inspect or change the markup.

A saved page may look incomplete if it depends on CSS, JavaScript, fonts, images, or data that were not saved beside it. Relative URLs resolve from the file's location, so moving the page without its companion folders can break images and styling.2

Treat an unfamiliar HTML file like an unfamiliar website. It can run scripts, submit forms, redirect the browser, or request remote resources. Open it with current software, do not enter credentials into an untrusted page, and inspect suspicious source first.1

Poly support for .html

Poly recognizes .html filenames and provides page thumbnails plus a rendered preview. It also indexes the full stored source for exact and semantic search, including readable text, tags, links, and attributes.

The Poly agent can reason about the document's content and structure. The rendered result and source answer different questions: the preview shows what the file can display with its available resources, while source search still finds markup or text when a dependency is missing. Poly does not automatically collect every linked resource or turn one file into a complete website capture.

History of .html

Tim Berners-Lee wrote the first WorldWideWeb browser and editor in 1990, then released it with the first web server in 1991. He also published the early HTML, HTTP, and web-identifier specifications so others could build compatible tools.3 The IETF documented established HTML practice as HTML 2.0 in November 1995.4

HTML later passed through numbered W3C recommendations. Today, the continuously maintained HTML Standard defines both authoring rules and the error recovery browsers use for imperfect pages.5 The .html suffix became the natural descriptive spelling, while the three-character .htm alternative remains for compatibility with older tools and conventions.

Working with .html and alternatives

Save modern authored HTML as UTF-8. When declaring the encoding inside the file, place the complete <meta charset="utf-8"> declaration within the first 1,024 bytes.6

NeedPractical choiceMain tradeoff
Editable, responsive web page.htmlMay depend on external resources
Fixed layout for sharing or printingPDFLoses most interactivity
Readable content for editingMarkdown or plain textLoses page structure and styling
Page plus its dependenciesWeb archive or complete site folderLess convenient than one file

Printing an HTML page to PDF captures a particular rendering. Converting it to Markdown or plain text preserves much of the prose but usually drops scripts, forms, layout, and attributes. Dynamic sites may also depend on authentication and live data, so no static export necessarily preserves the full application.

Footnotes

  1. WHATWG. HTML Standard: text/html Media Type Registration. Lists the common extensions, states that HTML has no unique magic number, and documents security considerations. 2 3
  2. MDN Web Docs. Dealing with Files. Describes opening local HTML files and resolving relative file paths.
  3. Berners-Lee, T. The World Wide Web: A Very Short Personal History. World Wide Web Consortium.
  4. Berners-Lee, T., and D. Connolly. RFC 1866: Hypertext Markup Language - 2.0. Internet Engineering Task Force, November 1995.
  5. WHATWG. HTML Standard. The living standard defines HTML syntax, elements, APIs, and browser processing.
  6. WHATWG. HTML Standard: Specifying the Document's Character Encoding. Requires UTF-8 for authored documents and defines placement of an in-document encoding declaration.
© Poly Corp. 2026