What are the practical limits on file extension name lengths?

Posted by GorillaSandwich on Super User See other posts from Super User or by GorillaSandwich
Published on 2011-01-14T16:47:02Z Indexed on 2011/01/14 16:55 UTC
Read the original article Hit count: 200

Filed under:
|

I started using DOS back before Windows, and ever since have taken it for granted that

  • Every file has a file extension, like .txt, .jpg, etc
  • That extension is always short (usually 3 letters)

I learned early that the extension is basically just a hint to the OS as to what the content type is. Eventually I got exposed to Mac and Linux, files with no extensions, etc. And of course I've seen shorter extensions, like .rb and .py.

I just noticed that markdown-formatted files can have the extension .markdown, and it made me wonder - how long can that extension be? If I make it .mycrazylongextensiontypewoohoo, will certain operating systems or programs choke on the file? Are extension names generally short just for convenience, or is this based on some limitation, legacy or current?

© Super User or respective owner

Related posts about filenames

Related posts about sysinternals