Why can't file names be longer than 30 characters?

A reader is told his long filenames are unacceptable, despite OS X's support for them.

computer files stock laptop

Oleksandr Bogonis is a Windows-to-OS X switcher who generally likes the move, but he’s frustrating by a limit he seems to have run up against:

A field for a file name in “Save as...” box is critically short. It allows one to enter 30 or so symbols. I often save files which have long names—up to 100 symbols.

He wonders if there’s a trick to increase file-name length. The real limit is 255 characters, so something is definitely off.

It could be one of a few scenarios:

  • You’re trying to save out of Apple’s Mail app and it has a corrupted index. Many users across many forums and years report being told the character limit for a volume is 31 characters, then re-indexing Mail, and the problem disappears. Go figure! But if it works, it works. The simplest way to fix Mail is to re-do your whole Spotlight index per Apple’s instructions. (There are outdated instructions on Macworld and elsewhere for deleting Mail’s index by itself, but these seem unreliable in El Capitan.)

  • If you’re using a network or external volume that’s not formatted for Mac OS X (as HFS+), you may be hitting a limit for that other format.

  • Some software was never properly updated to move from a previous maximum 31-character limit many, many years ago—this dates back to Mac OS 9! But for compatibility’s sake, some software throttled filename length. Apparently, some apps still adhere to this.

  • Your full Unix path may be too long. There’s a soft limit of 1024 characters for the entire path from root to your file (like /Users/glenn/Documents/Hope Springs Eternal/Smashmouth/Ringbearer/Oodles.txt/). Some users report being able to create paths longer than that, but then experiencing problems.

  • You may need to repair your disk. The best way is to boot into OS X Recovery, run Disk Utility, and run Repair Disk on your startup volume. Restart your Mac ( > Restart), then hold down Command-R until you get the recovery screen. Launch Disk Utility, select the startup volume, and click Repair Disk; do the same for the partition in that volume. Then  > Restart.

Ask Mac 911

We’re always looking for problems to solve! Email yours to mac911@macworld.com including screen captures as appropriate. Mac 911 cannot reply to email with troubleshooting advice nor can we publish answers to every question.

Shop Tech Products at Amazon