HTML | DOM Window stop() Method
The stop() method in DOM is used to stop the window from loading resources in the current browsing context, similar to the browser’s stop button.
Syntax:
window.stop()
Property Values:
No return value
Example: Stop window from loading.
<!DOCTYPE html> <html> <style> h1 { color: green; } </style> <head> <script> // Stop window loading. window.stop(); </script> </head> <body> <h1>GeeksforGeeks</h1> <p>The stop() method stops this text and the iframe from loading.</p> </iframe> </body> </html> |
chevron_right
filter_none
Output:
Without window.stop() method:

With window.stop() method:

Supported Browsers:
- Google Chrome
- Firefox
- Safari
- Opera
Recommended Posts:
- HTML | Window createPopup() Method
- HTML | Window moveBy() Method
- HTML | Window atob( ) Method
- HTML | Window moveTo() Method
- HTML | Window btoa( ) Method
- HTML | Window alert( ) Method
- HTML | Window resizeBy() Method
- HTML | Window resizeTo() Method
- Javascript | Window Blur() and Window Focus() Method
- HTML | Window name Property
- HTML | Window self( ) Property
- HTML | Window top( ) Property
- HTML | Window sessionStorage( ) Property
- HTML | Window outerWidth Property
- HTML | Window pageXOffset Property
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.



