How to open a .htm file
HTML document · Web / text
An .htm file is exactly the same as .html: a web page. Double-click it and your browser opens it. To see the code, open the same file in a text editor.
What a .htm file actually is
HTM and HTML are one format with two spellings. The shorter one dates from early Windows and DOS, which allowed only three characters in an extension.
No browser or editor treats them differently, and renaming one to the other changes nothing.
Why it will not open
It nearly always opens. What surprises people is a saved page that appears without images or styling, because those live in a separate folder that was not copied along with it.
Renaming it to an extension you can open will not help: changing the extension does not convert the file, it only changes what Windows tries to open it with.
Step by step
Windows
- 01Double-click, or drag the file onto any browser window.
- 02To edit, right-click, choose "Open with", then Notepad, VS Code or Notepad++.
- 03If images and layout are missing, look for a folder beside the file with the same name and an "_files" suffix. The page needs it.
macOS
- 01Double-click to open in Safari, or drag onto Chrome or Firefox.
- 02To edit, open it in TextEdit with Format set to Plain Text so it does not save as styled text.
Programs that open .htm
Our pick, in order. Every one links to the publisher's official download URL and the SHA-256 hash of the installer. Once you have downloaded it, you can check the file against our index before you run it.
If you end up downloading one of these from somewhere other than the publisher, what you can and cannot verify about that is worth two minutes.
- Sublime Text 4Sublime is a sophisticated cross-platform text editor for code, markup and prose.v4.0.0.420000 · 2 hashed installers92
- Microsoft Visual Studio CodeMicrosoft Visual Studio Code is a code editor redefined and optimized for building and debugging modern web and cloud applications. Microsoft Visual Studio Code is free and available on your favorite platform - Linux, macOS, and Windows.v1.132.0 · 4 hashed installers100
- VivaldiPowerful, Personal and Private web browser.v8.1.4087.64 · 3 hashed installers100
Also registers .htm in its manifest
Taken straight from publisher manifests. Some of these handle the format for a narrow purpose rather than as their main job.
- Google Chromev151.0.7922.138 · 3 hashed installers100
- Microsoft Edgev151.0.4129.78 · 3 hashed installers100
- Mozilla Firefox (en-US)v153.0.3 · 3 hashed installers100
- Opera GX Stablev134.0.5954.67 · 2 hashed installers100
- Opera Stablev134.0.5954.46 · 3 hashed installers100
- Tor Browserv15.0.19 · 2 hashed installers100
- Waterfoxv6.6.17 · 1 hashed installer100
- Yandex Browserv26.8.0.1788 · 1 hashed installer100
- Bravev151.1.93.136 · 6 hashed installers95
Common questions
- Is .htm the same as .html?
- Yes, identical. The three-letter spelling is a leftover from DOS and early Windows extension limits. Every browser and editor treats them the same way.