Why is url case sensitive
If you want to make your URLs case sensitive for the different pages of your site, use a Linux or Unix-based server. But as mentioned earlier, having case sensitive URLs may cause problems later on the maintenance side.
This is why it is still best to have your pages in the lower case to reduce linking or redirection problems in the future. While your browser automatically shifts the URL into lowercase when you type, writing it in lowercase makes it easier for people to remember. Remember, people are not going to think about how to type your name; they will just remember what your name is. Smartphones have dedicated a key for it on the virtual keypad on your browser.
Using fancy domain name extensions can be tricky and may lead your audience elsewhere, especially if you choose a very cumbersome extension that has more than one syllable in it.
Remember that your domain name is your location on the web, and every letter you use adds a step for your audience to reach you. Make sure your domain name is easy to spell and pronounce. To give you an idea of how easy it should be, as you flash your domain name on the screen during a presentation, make sure you can say it as your website name appears on the screen.
It should be instantaneous and can be embedded in the minds of your audience in a second or two. Also, having an easy to say and spell domain name will come in handy when you get an email to go with your website.
A short yet easy to say and spell email domain will be helpful when you drop your contact information in a conversation. For one, hyphens are prone to typographical errors.
Like spelling, not everyone may get your domain name immediately. They may be able to remember your name but may forget about the hyphen. Also, domain names that have hyphens are often associated with spam. Consider other alternatives. Double letters are prone to typographical errors. Besides, it may be hard to read, and makes your name harder to brand.
You need to remember that your name needs to be read easily, and having double letters encumbers readers from identifying your brand. Does capitalization and spaces matter in Internet addresses? Is it useful? Improve this answer. Community Bot 1.
Kobi Kobi 1, 9 9 silver badges 10 10 bronze badges. In truth, the scheme defines what to expect in the rest of the URL. See page 55 of ietf. Nicely detailed! I was going from a historical point of view. It was originally the file path that required to be case sensitive only if you were hitting the file system. Otherwise, it was not. But today, things have changed. For example, parameters and CGI did not exist originally.
Your answer takes a current day perspective. I had to reward your efforts!! You really dug in on this one! Who knew this would blow-up the way it did?? Kobi seems to be asserting the latter, he prefers that case-sensitive should mean "any change in case is significant", which of course is not true of URLs. You prefer the former. It's just a matter of how sensitive they are to case. Show 4 more comments. I think you argument is flawed. He got to design http URLs. If there ever were any web servers that just passed the URL path to the file system then they were insecure and the introduction of URL encoding broke compatibility with them.
Given that the path is being processed before handing to the OS smashing case would have been easy to implement. Therefore I think we have to regard this as a design decision not an implementation quirk.
WilliamHay This has nothing to do with Berners-Lee or the design of the web. It is about limitations and requirements of the OS. I am a retired systems internals engineer. I worked on these systems at the time. I am telling you exactly why URLs are case sensitive. It is not a guess. It is not an opinion. It is a fact. My answer was intentionally simplified. Of course there are file checks and other processes that can be done prior to issuing any open statement. And Yes!
Whether URLs are case sensitive has nothing to do with the design of the web? Argument from Authority followed by Argument by Assertion. That web servers pass the path component of a URL more or less directly to an open call is a consequence of the design of URLs not a cause of it.
Servers or smart clients in the case of FTP could have hidden the case sensitivity of filesystems from the user. That they don't is a design decision. WilliamHay You need to slow down grass hopper and reread what I have written. At no time did I say web servers passed values without processing. I did say that OS services are commonly used and that the file system requires an exact match to succeed.
WilliamHay Please understand that you and I are thinking at cross-purposes. All I was saying in my answer is that for some OSes, file system calls are case sensitive by design.
Applications that use system calls, and most do, are limited to the enforcement of the OS rules - in this case, case sensitivity. It is not impossible to bypass this rule. In fact this may be somewhat trivial in some cases though not practical. I used to routinely bypass the file system in my work to unscramble hard drives that went kablooie for one reason or another or to analyze database file internals, etc.
Add a comment. Case insensitivity requires more work when looking for a match either in the OS or above it. William Hay William Hay 1 1 silver badge 4 4 bronze badges. So internationalization is unlikely to be an original reason. Without specifying a charset its isn't possible to know which octets represent the same character except for case. Re 4: It's actually worse than that.
Dotted and dotless I are a demonstration of the more general principle that, even if everything is UTF-8 or some other UTF , you cannot capitalize or lowercase correctly without knowing the locale to which the text belongs. In the default locale, a capital Latin letter I lowercases to a lowercase Latin letter i, which is wrong in Turkish because it adds a dot there is no "Turkish capital dotless I" code point; you're meant to use the ASCII code point. Throw in encoding differences, and this goes from "really hard" to "completely intractable.
Why wouldn't the URL be case sensitive? Now, with all that background, here are some specific answers to the specific questions: When URLs were first designed, why was case-sensitivity made a feature? David Richerby 4 4 bronze badges. Reviewed every case of "browsers" and made multiple replacements. Thank you for pointing this out so some quality could be improved. I have received several excellent answers to my question, ranging from the historical to the technical.
I am hesitant to go against the grain and accept a lower-rated answer, but TOOGAM's answer was the most helpful to me. This answer is thorough and extensive yet it explains the concept in an uncomplicated, conversational fashion that I can understand. And I think this answer is a good introduction to the more in-depth explanations. The reason Windows has a case-insensitive filesystem is due to it's DOS heritage.
Since it couldn't display lower-case, mixed-case wasn't supported. But all that feels like it's answering the wrong question, anyway. Dewi Morgan Dewi Morgan 1 1 silver badge 4 4 bronze badges. Some sites use some kind of mechanism to convert any query to all lowercase or something consistent.
In a way, this is smart. No, they shouldn't. This functionality can be, and often is, added in when it is desirable e. To impose this kind of change as default behavior -- or worse, immutable behavior -- would be more disruptive than the relatively rare occasion where someone has to manually type in a URL beyond the host name.
For a good example of why not to do this, recall the fiasco when Network Solutions "fixed" non-existent domain errors from public DNS queries. It just don't seem to be a very popular thing to do. I would like to add some more points. This could be the reason. Mani Mani 1, 7 7 silver badges 18 18 bronze badges. Windows did not take off really until Windows 95 and it took NT 4.
Let me modify it. Indeed, the WorldWideWeb was initially developed on Unix-based systems, which have case-sensitive file systems, and most URLs mapped directly to files on the file system. This page is showing a generic answer. To see a more detailed answer customized for you, type your domain name here:. Our web servers usually do not treat URLs as being case sensitive.
This means that your visitors likely won't see an error page if they follow a link that accidentally points to a file named "mypage. The sections below have more details:.
0コメント