Add DataEasy to WordPress
Option 1: a headers plugin (easiest)
- Install a plugin that adds code to the site header, such as WPCode or Insert Headers and Footers.
- Paste the snippet in the Header section and save.
<script
defer
data-website-id="YOUR_WEBSITE_ID"
data-domain="yourdomain.com"
src="https://dataeasy.app/js/script.js"
></script>Option 2: your theme
In Appearance → Theme File Editor, open header.php and paste the snippet right before </head>. Use a child theme, otherwise the change is lost on the next theme update. Or add it from your child theme's functions.php:
functions.php
add_action('wp_head', function () {
echo '<script defer data-website-id="YOUR_WEBSITE_ID" data-domain="yourdomain.com" src="https://dataeasy.app/js/script.js"></script>';
});Logged in as admin? Your own visits are counted too. Exclude them with the ignore flag.