coderef

display-mode media queryLimited availability

The display-mode CSS media query sets styles based on whether the web page is in an ordinary browser tab mode or another mode, such as fullscreen, standalone, or minimal-ui.

Not yet supported in all major browsers — check the table and provide a fallback.

Browser support

DesktopChrome
1–46Not supported
47+Supportedsince Dec 1, 2015
Current: 155
Edge
12–18Not supported
79+Supportedsince Jan 15, 2020
Current: 154
Firefox
✕Not supportedup to 157
Current: 157
Safari
✕Not supportedup to 27
Current: 27
MobileChrome Android
✕Not supportedup to 155
Current: 155
Firefox Android
4–115Not supported
116+Supportedsince Aug 1, 2023
Current: 157
Safari iOS
✕Not supportedup to 27
Current: 27

How to use

Not supported in Firefox, Safari, Chrome Android, Safari iOS. Use feature detection below and provide a fallback (or a polyfill) for those browsers.

Example

Full syntax and examples are on MDN: display-mode.

Feature detection

There’s no simple runtime check for this feature; rely on the support table and test in your target browsers.

Sub-features

Support for each part of the feature (5). The overall table above shows when the whole feature works.

Sub-featureChromeEdgeFirefoxSafariChrome AndroidFirefox AndroidSafari iOS
@media.display-mode42794713424712.2
@media.display-mode.browser427947134211612.2
@media.display-mode.fullscreen4779✕✕✕116✕
@media.display-mode.minimal-ui4279571342116✕
@media.display-mode.standalone4279571342116✕