Skip to main content
Cool Popup works on any WordPress site. You have two ways to install it: editing your theme’s header.php directly, or using a free plugin if you prefer not to touch theme files.
1

Log in to your WordPress admin

Go to your WordPress dashboard (e.g., https://yoursite.com/wp-admin).
2

Open the Theme Editor

Go to Appearance → Theme Editor (sometimes labelled Appearance → Theme File Editor).
3

Select header.php

In the file list on the right, click header.php.
4

Paste the Cool Popup snippet

Find the closing </head> tag and paste the snippet on the line just before it.
<script src="https://cdn.coolpopup.com/popup.js" data-id="YOUR_SITE_ID" async></script>
5

Save the file

Click Update File to save your changes.
The manual method works with any WordPress theme, including block themes.
Edits to header.php can be overwritten when you update your theme. To prevent this, use a child theme or install via the plugin method below.

Method 2: Via the Insert Headers and Footers plugin

1

Install the plugin

Go to Plugins → Add New, search for Insert Headers and Footers, then install and activate it.
2

Open the plugin settings

Go to Settings → Insert Headers and Footers.
3

Paste the snippet

In the Scripts in Header box, paste the Cool Popup snippet:
<script src="https://cdn.coolpopup.com/popup.js" data-id="YOUR_SITE_ID" async></script>
4

Save

Click Save to apply the changes.

Finding your Site ID

Replace YOUR_SITE_ID with the value from Dashboard → Settings → Installation in your Cool Popup dashboard.

Verifying the installation

Visit your site, open browser DevTools (F12 or right-click → Inspect), and go to the Network tab. Reload the page and filter by popup.js — you should see the script load with a 200 status code.