Skip to main content

GlobalEventHandlers.onmonetization

The onmonetization property of the GlobalEventHandlers mixin is the event handler for processing monetization events sent to the window.

Syntax

window.onmonetization = functionRef

Examples

window.onmonetization = function () {
alert('Web Monetization event triggered.')
}

Specifications

Browser compatibility

desktopmobile
Chrome
Edge
Firefox
Internet Explorer
Opera
Safari
WebView Android
Chrome Android
Firefox for Android
Opera Android
Safari on iOS
Samsung Internet
Puma Browser
onmonetization
YesYesYesNoYesNoNoNoNoNoNoNoYes
Full Support
No Support
You'll need to use a Web Monetization Extension