Today we’re going to discuss the IE User-Agent String – a term with which more administrators are becoming familiar since the launch of IE7. The User-Agent string identifies your browser to the server hosting the site that you are visiting. This allows the web server to provide content that is tailored for the specific browser being used.
So, first things first – deciphering the User-Agent string. Below is a sample user-agent string reported by Internet Explorer that highlights the tokens.
A couple of quick notes here – Internet Explorer identifies itself as a Mozilla 4.0 browser for historical reasons. The compatibility flag (“compatible”) is used by most browsers to indicate that the browser is compatible with a common set of features. The version token indicates the browser version number. In the example above, the browser is reported as IE7. Finally, the Platform token identifies the Operating System. In this case, the platform is “Windows NT 6.0” – Windows Vista. When viewing the user-agent string, you may also see additional tokens. These tokens identify optional features installed on the system – such as the examples below:
|.NET CLR||.NET Framework common language run time, followed by the version number|
|SV1||IE6 with enhanced security (XP SP2 & Windows 2003 only)|
|Tablet PC||Tablet Services are installed; number indicates the version number|
|Win64; IA64||System has a 64-bit processor (Intel)|
|Win64; x64||System has a 64-bit processor (AMD)|
|WOW64||A 32-bit version of IE running on a 64-bit processor|
Now that you know what the information means, how do you find out what Internet Explorer is reporting to the web server? There’s two different ways to find this information. One way is to query the registry values at:
- HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Internet Settings\5.0\User Agent
- HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Internet Settings\5.0\User Agent
If you don’t see any values in these keys for the basic browser or OS version it’s nothing to be alarmed about – it just means that the browser and OS versions are being reported as their default settings for whatever is installed (IE6 on XP SP2, IE7 on Vista etc). What you do want to pay attention to are the Pre Platform and Post Platform keys and any associated values. If a string value is added to the Post-Platform
So from this particular user-agent string output, I know I am running the 32-bit version of IE7 on a 64-bit platform (WOW64), on Windows Vista (Windows NT 6.0) that has the .NET Framework components for versions 1.1, 2.0 and 3.0 installed (the .NET CLR values) as well as the Infopath version 2 components.
OK – so what’s the point of this entire post? Other than explaining how to decipher the user-agent string, several customers have reported issues with websites not being IE7 compatible. In more than a few of these cases, the problem is not actually that the site cannot support the browser technology – it’s that the site doesn’t know what to do with the user-agent string that is presented by the browser and returns a confusing error message along the lines of:
- You do not have the most current version of Internet Explorer
- The Web site supports Microsoft Internet Explorer 6 or later versions
The long-term resolution for this issue lies with the owner of the web site. The site needs to be updated to correctly detect IE7. However, some sites have not completed their testing with IE7 so this presents a problem. One workaround is to use the User Agent String Utility referenced in Microsoft KB Article 923196. This utility allows you to report your browser as an IE6 browser rather than IE7 to problem sites. You could also directly modify the registry of the machine that you are on to always report IE6, however remember that there is an administrative overhead associated with this. At some point, those registry entries will need to be backed out! Remember however that changing your User-Agent string does not change the behavior of the browser itself – so the security enhancements for IE7 remain in force.
OK – that’s it for this post. Hopefully this will help you tackle some of the IE7 deployment and compatibility questions!
- MSDN Article: Understanding User-Agent Strings
- User Agent on Wikipedia
- IEBlog post – IE7 User Agent String (Beta 1)
- Detecting Internet Explorer more Effectively
- What’s my User Agent? website