It spoofs Netscape by starting its User-Agent with Mozilla/ because web servers were routinely browser sniffing and serving pages with frames - a feature supported by both Netscape and IE, but not other browsers of the era - to Netscape only.
Mozilla/5.0 is the general token that says the browser is Mozilla compatible, and is common to almost every browser today.
It is a long and sad story.
In summary:
Mozilla/1.0 (Win3.1)
. It is publicly renamed to Netscape, but in its User-Agent it keeps its original name .Mozilla/
because web servers were routinely browser sniffing and serving pages with frames - a feature supported by both Netscape and IE, but not other browsers of the era - to Netscape only.Mozilla/
, like the browsers before them had done. Plenty of other nonsense also results, like modern Chrome's User-Agent simultaneously claiming to be Mozilla, Chrome, Safari, and 'like Gecko'.I think it had to do with: http://en.wikipedia.org/wiki/User_agent#User_agent_spoofing
Back in the early days, Netscape (code named Mozilla) was the main rival of IE, and they wanted to prevent being rejected by sites rejecting browsers other than Netscape.
As mentioned by @Jason "Its a long story". Summing that story up "its just every browser pretends to be Mozilla"
After trying everything, I have finally used: http://www.useragentstring.com/
You can use the above website to get the formatted user agent and OS.
They have an API which you can use directly...
Because that's how Netscape identified itself, and Microsoft wanted to work with sites that would detect Netscape and reject anything else.
Reason for this are the infamous browser wars.
In short - browsers started to pretend to be some other browser, because some websites served content based on which browser asked for it and they also wanted content meant for other browsers.
I find it surprising it still haven't been solved to this day. Since userAgent
can't be safely removed for legacy reasons, why some new feature clearly identifying a browser wasn't introduced? Yes, most of the time you don't need browser detection, but rather a feature detection, but it is not built-in JS neither!
Mozilla/5.0 is the general token that says the browser is Mozilla compatible, and is common to almost every browser today. for more detail click here
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With