We're looking for a person or people to help audit MDN to find places we could speed up. Is this you or someone you know? Check out the RFP: https://mzl.la/2IHcMiE

Esta tradução está incompleta. Por favor, ajude a traduzir este artigo.


O evento unload é disparado quando a janela está descarregando seus conteúdos e recursos. A remoção dos recursos é processada após o evento unload ocorrer.


window.onunload = funcRef;
  • funcRef é a referência a uma função.


Using this event handler in your page prevents Firefox 1.5 from caching the page in the in-memory bfcache. See Using Firefox 1.5 caching for details.

Browsers equipped with pop-up window blockers will ignore all window.open() method calls in onunload event handler functions.

You can and should handle this event through window.addEventListener() and the unload event. More documentation is available there.


Specification Status Comment
HTML Living Standard
The definition of 'GlobalEventHandlers' in that specification.
Padrão em tempo real  
HTML 5.1
The definition of 'GlobalEventHandlers' in that specification.
The definition of 'GlobalEventHandlers' in that specification.

Compatibilidade de navegadores

We're converting our compatibility data into a machine-readable JSON format. This compatibility table still uses the old format, because we haven't yet converted the data it contains. Find out how you can help!

Feature Chrome Firefox (Gecko) Internet Explorer Opera Safari (WebKit)
Basic support (Yes) (Yes) (Yes) (Yes) (Yes)
Feature Android Firefox Mobile (Gecko) IE Phone Opera Mobile Safari Mobile
Basic support (Yes) (Yes) (Yes) (Yes) (Yes)

Etiquetas do documento e colaboradores

 Colaboradores desta página: macalha
 Última atualização por: macalha,