Limited other
beforeunload
The beforeunload event is fired when the current window is about to be unloaded. Typically this is used to display a dialog to confirm if users really want to leave the page when there is unsaved data that would be lost.
Baseline Status
Limited
Missing ≥1 target
First Core Launch
Firefox 1
2004-11-09
Core-3 Stability
1,493d (4.1y)
Last: Chrome (2008-12-11)
BCD Keys Mapped
4
Group: other
Browser Support Timeline
Browser Support Releases
| Browser | Type | Version | Release Date |
|---|---|---|---|
| Firefox | desktop | 1 | 2004-11-09 |
| Safari | desktop | 3 | 2007-10-26 |
| Chrome | desktop | 1 | 2008-12-11 |
| Firefox for Android | mobile | 4 | 2011-03-29 |
| Chrome Android | mobile | 18 | 2012-06-27 |
| Edge | desktop | 12 | 2015-07-29 |
Constituent MDN BCD Keys (Sample)
| BCD Key | Area | Core-3 TTA |
|---|---|---|
| api.BeforeUnloadEvent | DOM API | 2,884d (7.9y) |
| api.BeforeUnloadEvent.user_interaction | DOM API | 602d (1.6y) |
| api.Window.beforeunload_event | DOM API | 1,493d (4.1y) |
| api.Window.beforeunload_event.preventdefault_activation | DOM API | 4,459d (12.2y) |