All Collections
Publisher Help
How To Install PushMonetization On Your Website
How To Install PushMonetization On Your Website

Step by step instructions to help you get started!

Tom Voitik avatar
Written by Tom Voitik
Updated over a week ago

1.  Enable HTTPS (SSL) On Your Website.

In order for web push notifications to work natively, your site needs to have an SSL certificate. You can use CloudFlare for free to get your site under HTTPS.

2.  Install Files

Download the zip file containing two files (manifest.json and sw.js)

Unzip the zipfile and place the two files (manifest.json and sw.js) in to the root of your website.  For example, if your website is example.com the two files should be accessible from example.com/manifest.json and example.com/sw.js


3.  Add Code To Your Website.

Place the following code inside the <body> on every file of your website you want a user to be able to subscribe from.  Replace {PROPERTY_ID} with your own property id.

<script>
var pushconfig = {
    property:"{PROPERTY_ID}",
};
</script>
<script src="https://js-beta.pushmonetization.com/webpush.js"></script>

Did this answer your question?