The problem 🔗
At some point or another, everyone who uses Windows must have tried to enter a file name, unwittingly also entering a restricted / forbidden / invalid / banned / illegal character, only to be blocked and informed of the following:
A file name can’t contain any of the following characters:
\ / : * ? ” < > |
Personally, I’ve always found it irritating to have such common punctuation disallowed.
The explanation 🔗
Basically, Windows blocks these characters from being used in file names because the same characters are used in its coding so it would get tripped up otherwise. Unix-based Operating Systems such as macOS also have forbidden characters for the same reason but they’re significantly fewer.
What many people don’t know is that Windows’ file names support the Unicode character set and it only blocks the ASCII printable character versions:
Symbol | Name | Hex code | Decimal code |
---|---|---|---|
\ | Backslash | 5C | 92 |
/ | Slash / divide | 2F | 47 |
: | Colon | 3A | 58 |
* | Asterisk | 2A | 42 |
? | Question mark | 3F | 63 |
" | Double quotes / speech marks | 22 | 34 |
< | Less than / open angled bracket | 3C | 60 |
> | Greater than / close angled bracket | 3E | 62 |
| | Vertical bar / pipe | 7C | 124 |
So, what if you could find Unicode characters that look like the “original” characters but aren’t technically the same…? Spoiler: you can.
The workaround 🔗
Using https://unicode-search.net/unicode-namesearch.pl?term=, I have found Unicode characters that look like the original characters but aren’t the same so they can be used in Windows file names!
Symbol | Name | Unicode code |
---|---|---|
⧵ | Reverse Solidus Operator | U+29F5 |
∕ | Division Slash | U+2215 |
꞉ | Modifier Letter Colon | U+A789 |
⁎ | Low Asterisk | U+204E |
? | Fullwidth Question Mark | U+FF1F |
“ | Left Double Quotation Mark | U+201C |
” | Right Double Quotation Mark | U+201D |
< | Fullwidth Less-Than Sign | U+FF1C |
> | Fullwidth Greater-Than Sign | U+FF1E |
⏐ | Vertical Line Extension | U+23D0 |
So, how can you type these?
Edit: For a significantly better version of the below, I now use an AutoHotkey script which automatically replaces the characters when File Explorer windows are open so you don’t have to remember key combinations. This is available in my other blog post “Windows apps for an efficient workflow“.
Personally, I use AutoHotkey and the following custom script (.AHK
file) so that all I have to do is press left Alt (LAlt
) or right Alt (RAlt
) and the normal key:
Below is a demonstration of this:
I have been using these characters in file names ever since in Dropbox, OneDrive for Business, Microsoft Word, Adobe Reader, etc on Windows, iOS, and web and, as of 2020 ∕ 09 ∕ 10 (😉), I have experienced no compatibility problems.