This article provides answers to some of the most common questions about document modes in Internet Explorer.
Original product version: Internet Explorer
Original KB number: 4551933
How does Internet Explorer determine the document mode
By default, Windows Internet Explorer 8 uses Internet Explorer 8 mode, and Windows Internet Explorer 9 uses Internet Explorer 9 mode, and so on. However, Windows Internet Explorer uses several criteria to determine which document mode to use. For example, if an HTML page contains a valid <!DOCTYPE> declaration (see HTML5), Internet Explorer uses one of the standards-based document modes. But if there's no valid <!DOCTYPE> declaration, Internet Explorer uses Quirks mode. Only if there's no <!DOCTYPE> declaration does a page render in Quirks mode.
Microsoft Edge Legacy is designed to be interoperable for the web, and is intended to run primarily in EdgeHTML mode.
Microsoft Edge version 77 or a later version uses the Blink rendering engine. It won't render under EdgeHTML mode.
The following rules determine how Internet Explorer selects the document mode:
- The Developer Tools setting overrides any document mode that's specified by a webpage. The setting remains active for the lifetime of the tab.
- In Internet Explorer 9, if the document is hosted in an iframe element, the document mode is determined by the document mode of the top-level webpage. Subdocuments can't be rendered in Internet Explorer 9 mode unless the top-level document is also in Internet Explorer 9 mode.
- A meta tag that has a value of X-UA-Compatible or an HTTP response header can override items in the Compatibility View Settings list and the doctype. This is true unless the X-UA-Compatible value is a Compatibility View setting, such as IE=EmulateIE7 or IE=EmulateIE8.
- The Compatibility View settings can force a webpage to be displayed in a less-standard document mode.
- The Local Compatibility Site list, the Microsoft Compatibility Site list, and the Enterprise Mode IE Compatibility Site list can force a webpage to be displayed in other document modes.
- Group Policy settings override other settings and force all webpages to be displayed in the specified document mode.
- If none of these rules apply, the <!DOCTYPE> declaration determines whether the webpage renders in Standards mode, Almost Standards mode, or Quirks mode.
The sections (184.108.40.206 - 220.127.116.11) that are explained in the following article show that these rules affect how Internet Explorer selects between document modes. Most of the sections don't apply to Microsoft Edge unless this is explicitly indicated:
Additionally, the following rule determines how Microsoft Edge selects the document mode:
For more information about how to configure document modes, see the following articles:
What is Enterprise mode
The Document mode selection flowchart explains clearly how Internet Explorer determines document modes.
The Internet Explorer 11 Enterprise mode site list lets you specify document modes for specific websites. This helps you fix compatibility issues without changing a single line of code on the site. This addition to the site list is a continuation of our commitment to help you upgrade and stay up to date regarding the latest version of Internet Explorer, while preserving your investments in existing apps.
When do I use document modes versus Enterprise node
While the Enterprise mode functionality provides great compatibility for you on Internet Explorer 8 or Internet Explorer 7, the new document mode capabilities can help you stay up-to-date regardless of which versions of Internet Explorer are running in your environment. Therefore, we recommend that you start your testing process as follows:
- If your enterprise primarily uses Internet Explorer 8 or Internet Explorer 7, start testing by using Enterprise mode.
- If your enterprise primarily uses Internet Explorer 10 or Internet Explorer 9, start testing by using the various document modes.
Because you might have multiple versions of Internet Explorer deployed, you might have to use both Enterprise mode and document modes to effectively move to Internet Explorer 11.
Enterprise mode takes precedence over document modes.
What is the difference between EmulateIE7 and Internet Explorer 7 document modes
In Internet Explorer 8, Microsoft introduced compatibility options to allow Internet Explorer to act as if it were Internet Explorer 7. This change lets users view both fully compliant sites and compatibility views of web content that required Internet Explorer 7.
This has been extended up to and including Internet Explorer 11 in order to support the Compatibility View feature - or, at least, document modes.
IE=7: Display in Internet Explorer 7 Standards mode.
IE=EmulateIE7: Webpages are displayed in Internet Explorer 7 Standards mode, regardless of the declared !DOCTYPE directive. Failing to declare a
!DOCTYPE directive causes the page to load in Quirks.
When you specify the version (for example, Internet Explorer 7), you set a requirement that the page must use the Internet Explorer 7 Standards mode.
Officially, the rules for rendering a webpage are evaluated in the following order by Internet Explorer:
- Internet Explorer Developer Tools settings – Manually setting the browser mode (user agent string in Internet Explorer 11) and Document mode overrides all other settings.
- Web content/document is in an iframe – The rendering or compatibility mode for the page and for any contained iframes is set by the page. Iframe settings (for example, iframe specific X-UA-compatible.) are ignored.
- X-UA-Compatible meta tag – This value can be specified in the web application generated page header or inserted by the web server or application server to select Internet Explorer's Document mode.
- The Compatibility View setting – If X-UA-compatible is not specified, the user's local browser Compatibility View setting will apply. This is the equivalent (for non-standard pages) of the X-UA-Compatible EmulateIE7 setting.
- <!DOCTYPE> setting – If none of the previous mechanisms are used, the <!DOCTYPE> tag selects the rendering of Standards (or Almost Standards) or IE 5 Quirks mode.
For details about how document modes are manipulated, see Deprecated document modes and Internet Explorer 11.
For more general information about document modes, see Document Modes.
How can I configure browser emulation for web browser controls in Internet Explorer
By default, a WebOC Project will load in Internet Explorer 7 Document mode.
For Internet Explorer 8 and later versions, the FEATURE_BROWSER_EMULATION feature defines the default emulation mode for Internet Explorer, and supports the following values. To control the value of this feature by using the registry, add the name of your executable file to the following setting, and set the value to match the desired setting.
Registry key location:
Add the process of your WebOC Application:
Value: (DWORD) 00009000
For more information, see Internet Feature Controls (B..C).