Why do all browsers' user agents start with "Mozilla/"?

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...


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.


It is a long and sad story.

In summary:

  1. Mozilla browser gets released, with User-Agent Mozilla/1.0 (Win3.1). It is publicly renamed to Netscape, but in its User-Agent it keeps its original name .
  2. Internet Explorer is released. 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.
  3. Over time, Gecko, Konqueror, Opera, Safari and Chrome each decide to similarly spoof the User-Agent of some previous browser in order to manipulate browser-sniffing web pages into correctly understanding their browser's features. As part of this spoofing, all the browsers start their User-Agents with 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'.

Tags:

User Agent