A User Agent string is a string that your browser sends every time it connects to a website, as part of the HTTP header. Because of HTML rendering differences among browsers, many sites have Javascript that detect User Agent strings; the site can then serve content formatted for that specific browser. Some sites also analyze collected User Agent data to see what kind of browser people are using; Google Zeitgeist is an example of this.

User Agent strings vary; usually, when viewing server logs, by and far, the most common User Agent string is:

Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)

Microsoft Internet Explorer 6 running on Windows XP. The Mozilla section is there to be compatible with legacy Internet sites that refuse to serve content to non-Mozilla browsers.

Some User Agents are a bit more detailed than others; Mozilla's UA is a good example

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.0.0) Gecko/20020530

Not only does it show what version of Mozilla you're running, it also details if you have strong encryption (the U), what locale you're using (en-US), the revision (v1.0.0), and the build date (Gecko/20020530)

Some sites (online banking, mostly) nowadays will reject you if you're using a non-IE browser. The thinking behind this is that since MSIE has ~95% of the market, no time and effort should be wasted coding for browsers only 2% of people use. This is stupid. Ironically, many websites will allow Netscape 4.x, which is notorious for its CSS/DHTML incompatibility in, while rejecting Netscape 5.x, which renders far better. Many tools exist for changing your User-Agent header for such situations, or whenever you want to protect your privacy.

Log in or register to write something here or to contact authors.