Web/API/Window/print

From Get docs

Opens the Print Dialog to print the current document.

In most browsers, this method will block while the print dialog is open. However in more recent versions of Safari, it may return immediately.

Syntax

window.print() 

Specification

Specification Status Comment
HTML Living StandardThe definition of 'print()' in that specification. Living Standard

Browser Compatibility

Update compatibility data on GitHub

Desktop Mobile
Chrome Edge Firefox Internet Explorer Opera Safari Android webview Chrome for Android Firefox for Android Opera for Android Safari on iOS Samsung Internet
print

Chrome Full support 1

Notes'

Full support 1

Notes'

Notes' Starting with Chrome 46, this method is blocked inside an <iframe> unless its sandbox attribute has the value allow-modals.

Edge

Full support 12

Firefox

Full support 1

IE

Full support 5

Opera Full support 6

Notes'

Full support 6

Notes'

Notes' Starting with Opera 33, this method is blocked inside an <iframe> unless its sandbox attribute has the value allow-modals.

Safari

Full support 1.1

WebView Android Full support 1

Notes'

Full support 1

Notes'

Notes' Starting with WebView 46, this method is blocked inside an <iframe> unless its sandbox attribute has the value allow-modals.

Chrome Android Full support 18

Notes'

Full support 18

Notes'

Notes' Starting with Chrome 46, this method is blocked inside an <iframe> unless its sandbox attribute has the value allow-modals.

Firefox Android No support No

Notes'

No support No

Notes'

Notes' See bug 1247609.

Opera Android Full support 10.1

Notes'

Full support 10.1

Notes'

Notes' Starting with Opera 33, this method is blocked inside an <iframe> unless its sandbox attribute has the value allow-modals.

Safari iOS

Full support 1

Samsung Internet Android Full support 1.0

Notes'

Full support 1.0

Notes'

Notes' Starting with Samsung Internet 5.0, this method is blocked inside an <iframe> unless its sandbox attribute has the value allow-modals.

Legend

Full support  
Full support
No support  
No support
See implementation notes.'
See implementation notes.


See also