Element.requestFullscreen() asks the browser to show this element in fullscreen mode (MDN). It returns a Promise that resolves when the transition succeeds, or rejects on denial / error.
Pass the required arguments shown below. Check return values and browser support before you rely on the result.
Syntax
Call el.requestFullscreen. Start with this line.
JavaScript
el.requestFullscreen(options?)
Call
What it does
el.requestFullscreen(options?)
Primary signature.
el.requestFullscreen(...)
Call with the arguments your case needs.
Built into the browser. Call requestFullscreen(...) on an Element — no import required.
(documentElement fullscreen with navigationUI: "show")
How It Works
Optional object tunes fullscreen behavior (MDN).
navigationUI: "show" asks to keep browser nav chrome.
"hide" prefers a fuller screen for the element.
Default is "auto" — browser decides.
Compatibility
Browser Support
Element.requestFullscreen() is Limited availability on MDN (not Baseline). Desktop support is broad; mobile and embedded contexts vary. See the MDN requestFullscreen() reference.
✓ Limited availability
Element.requestFullscreen()
Async fullscreen request. Feature-detect and handle Promise rejection.
LimitedNot Baseline
Google ChromeYes*
Yes
Microsoft EdgeYes*
Yes
Mozilla FirefoxYes*
Yes
OperaYes*
Yes
Apple SafariPartial*
Partial
Internet ExplorerPrefixes / legacy
Partial
requestFullscreen()Partial
Bottom line: Call from a user gesture. Pair with exitFullscreen / fullscreenElement. Always .catch() failures.
Frequently Asked Questions
It issues an asynchronous request to display the element in fullscreen mode (MDN). It returns a Promise that resolves when the transition completes.
No. MDN does not mark it Deprecated, Experimental, or Non-standard. It is Limited availability (not Baseline) because support varies across browsers.
A Promise that resolves with undefined when fullscreen is active, or rejects if permission is denied or the element is not eligible (MDN).
Yes. MDN: transient user activation is required — call it from a click or key handler, not on page load.
Call document.exitFullscreen(), or let the user press Esc. Check document.fullscreenElement to see what is fullscreen.
fullscreenchange when mode toggles successfully, and fullscreenerror when the request fails (MDN).