We recommend our managed component for sites that use Cloudflare Zaraz. Zaraz loads it alongside your other tools, so you don't edit your pages.
Install the managed component
- 1
Build the component
Clone our repository and build it. You need Node.js.
Terminalgit clone https://github.com/ciphera-net/pulse-zaraz.git cd pulse-zaraz npm install npm run build - 2
Deploy it to your Cloudflare account
Sign in with Wrangler and deploy the component as a Worker. It appears in your account as
custom-mc-pulse-analytics.Terminalnpx wrangler login npx managed-component-to-cloudflare-worker ./dist/index.js pulse-analytics - 3
Add it in Zaraz
In the Cloudflare dashboard, go to Zaraz → Tools Configuration → Third-party tools, click Add new tool, choose Custom Managed Component and pick
custom-mc-pulse-analytics. - 4
Allow its permission and save
Allow the one permission it asks for. Leave Domain empty to use your site's address, or type the domain you added in Pulse.
The permission it asks for
The component asks only for execute_unsafe_scripts, which Zaraz requires before a tool can add a script to your pages.
Clicks, copies and forms
To count clicks, copies and form submits as well, open Settings → General for your site in Pulse and turn on Clicks, copies and forms. Your setup stays the same.
Further settings
To learn about every setting, read its README on GitHub.
Need a hand?
Tell us what you're setting up. We're happy to help.