XRSession.end()

Draft
This page is not complete.

Secure context
This feature is available only in secure contexts (HTTPS), in some or all supporting browsers.

The end() method of the XRSession interface requests shutdown the current XR session and returns a promise that resolves when the session ends.

This function can be used to shut down an active XR session and then execute a some code right after that.

Syntax

XRSession.end();

Parameters

None.

Return value

A promise that resolves without a value after any platform-specific steps related to shutting down the session have completed.

Example

TODO

Specifications

Specification Status Comment
WebXR Device API
The definition of 'XRSession.end' in that specification.
Working Draft Initial definition.

Browser compatibility

Update compatibility data on GitHub
DesktopMobile
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidFirefox for AndroidOpera for AndroidSafari on iOSSamsung Internet
end()Chrome No support NoEdge No support NoFirefox No support NoIE No support NoOpera No support NoSafari No support NoWebView Android No support NoChrome Android No support NoFirefox Android No support NoOpera Android No support NoSafari iOS No support NoSamsung Internet Android No support No

Legend

No support  
No support

Document Tags and Contributors

Contributors to this page: jpmedley, bershanskiy
Last updated by: jpmedley,