Is .htm better than .html?

He has: 43 posts

Joined: May 2005

I'm buzzing about making my website bigger and building it up, occasionally I accidently make a html file than a htm file, I was thinking, maybe one is better than the other?
What do you guys think, htm or html? Or are they so similar it's not worth worrying about?

Cheers Sonic

benj's picture

They have: 36 posts

Joined: Apr 2007

Sonic_Wolf;226598 wrote: I'm buzzing about making my website bigger and building it up, occasionally I accidently make a html file than a htm file, I was thinking, maybe one is better than the other?
What do you guys think, htm or html? Or are they so similar it's not worth worrying about?

Cheers Sonic

Doesn't matter...both the same. Microsoft "invented" the ".htm" when it was trying to coin the 3-letter extensions.

".html" is more popular around professionals.

Greg K's picture

He has: 2,145 posts

Joined: Nov 2003

For the most part, I'd say it makes no difference to the site for the general person.

Now you get someone like me, and just from my past experience in all of this, I see .htm as more amateurish (sp?) than .html just because about 10+ years ago when I was starting out, "professional" sites seemed to mainly have .html while the "average joe" site used .htm (because of windows prior to Win95 only supporting 8.3 filename structure (8 characters for the name, 3 for the extention, .htm)

But as far as SEO rankings and such, shouldn't make one it of difference.

-Greg

He has: 629 posts

Joined: May 2007

In general, the answers above are correct. However, there is one situation where it may be important to use one or t'other, and that is on your index or "home" page.

Depending on who hosts your site, the default page that comes up when a visitor omits the file name from the address may need a certain name. Or, more usually, a set of names. Some hosts require a file name of "index.htm" or "index.html" or "default.htm" and/or any number of others. As an example, my host allows "index. html" but "index.htm" does not work. Simply to be consistent, I name all my HTML files to end in HTML, but it's not really necessary.

YMMV.

On any platform, PC, Linux server, Windows server, whatever, the file type (the "dot - something") determines how it is treated. For example, the server I use will send a file ending ".XHTML" as, well, XHTML, not as HTML. For more on this, google "file MIME types."

Cordially, David
--
delete from internet where user_agent="MSIE" and version < 8;

She has: 70 posts

Joined: Nov 2007

Hmm... vote for neither. I use Drupal's clean URLS and don't have any extension. Smiling

Michelle

DarkLight's picture

He has: 287 posts

Joined: Oct 2007

Quote: from my past experience in all of this, I see .htm as more amateurish (sp?) than .html

Cheers Greg! Sad
Laughing out loud lol. JK, I use htm as it is less to type when homing in on a directory online, thats about the only difference i see myself.

All the best news here: https://newsbotnet.com

He has: 43 posts

Joined: May 2005

Cool, thanks for the heads up guys Smiling

Roo's picture

She has: 840 posts

Joined: Apr 1999

Yeah waaaaaay back in 199something when I put up my first God awful site on my ISP space that I had back then, you had to use .htm for some strange reason.

Now IMO it's best to use .html because that is what most people are used to, so it will be easier for users to remember that they went to contact.html vs contact.htm for example.

Roo

decibel.places's picture

He has: 1,494 posts

Joined: Jun 2008

You were probably using some version of Windows 3 (3.1, 3.1.1 aka "Windows for Workgroups") which was incapable of handling a 4 character extension.

Or perhaps software running on Windows 95/98 that was designed to work with Windows 3

My first computer was an IBM PS/2 with Windows 3.1.1 - it had I think 64KB of RAM and a 6MB hard drive - 16 color graphics card - modem? Hahahahaha Sticking out tongue

I kept my applications on 3.5" floppies and installed them, used them, uninstalled them, next...

When I worked in Kinkos in 1998 people were still coming in with 5 1/4" floppies, we had one machine for that.

They have: 6 posts

Joined: Oct 2007

both htm or html are same.

Suzanne's picture

She has: 5,507 posts

Joined: Feb 2000

Having no extension future proofs quite a bit (plus using a database reduces further issues with tinkering with files directly), but I like .html because it's so clear. For me, too, .htm just screams FRONTPAGE and MS and bad memories of buttons and backgrounds and embedded midi files. Laughing out loud

They have: 2 posts

Joined: Jun 2008

There are no difference between .htm and.html They are the same thing, The correct extension is .html, the cause the .htm extension was introduced was that Microsoft original OSs could only recognise an eight character name with a three character extension.

He has: 629 posts

Joined: May 2007

diamonddollars77 wrote:
There are no difference between .htm and.html

Well... It depends. I have come across hosts set up to accept index.htm as the home page but not index.html, and other hosts where the opposite is true.

I imagine that, in most cases, you are correct. But be aware that there are some exceptions.

Cordially, David
--
delete from internet where user_agent="MSIE" and version < 8;

decibel.places's picture

He has: 1,494 posts

Joined: Jun 2008

you should be able to change that in .htaccess add

AddType text/html .html

the htaccess Cheatsheet lists some other uses for .htaccess

He has: 629 posts

Joined: May 2007

Umm. I wasn't thinking of AddType - I was talking about the DirectoryIndex directive. That may or may not be alterable via .htaccess. But this is complicated by things such as MultiViews and URL rewriting... Sad

But this is getting off topic. I just wanted the OP to be aware that hosts can set up Apache in many different ways, so there are no hard and fast rules. Best to consult with your own hosting provider on these matters, methinks.

Cordially, David
--
delete from internet where user_agent="MSIE" and version < 8;

He has: 629 posts

Joined: May 2007

One final thought to get back to the original question:

If you can get away with it with your host, you may consider using .php for all your files, instead of .html. They don't have to contain any PHP processing directives to work, and you won't then have to change all your links should you decide to use PHP later.

Sorry for the excessive posting, but hope this helps.

Cordially, David
--
delete from internet where user_agent="MSIE" and version < 8;

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.