Element: fullscreenerror event

The fullscreenerror event is fired when the browser cannot switch to full-screen mode.

Bubbles Yes
Cancelable No
Interface Event
Event handler property onfullscreenerror

As with the fullscreenchange event, two fullscreenerror events are fired; the first is sent to the Element which failed to change modes, and the second is sent to the Document which contains that element.

For some reasons that switching into full-screen mode might fail, see the guide to the Fullscreen API.


const requestor = document.querySelector('div');

requestor.addEventListener('fullscreenerror', (event) => {
  console.error('an error occurred changing into fullscreen');



Fullscreen API Standard (Fullscreen API)
# handler-document-onfullscreenerror

Browser compatibility

BCD tables only load in the browser

See also