While optimizing my website’s performance, I discovered Cloudflare Zaraz - a tool that helps offload third-party scripts. After implementing it, my mobile performance score improved from around 75% to over 90%. Beyond the speed improvements, it also had a positive impact on SEO.
What is Cloudflare Zaraz?
Cloudflare Zaraz is a third-party manager that runs your third-party tools server-side instead of in the user’s browser. This means fewer requests, better privacy, and faster page loads.
I was able to offload Google Analytics and Simple Analytics scripts to Cloudflare’s edge network. This reduced the number of requests made by my website and improved the overall performance.
With Cloudflare Zaraz you can load tools such as analytics tools, advertising pixels and scripts, chatbots, marketing automation tools, and more, in the most optimized way.
Why use Zaraz?
- Performance: Third-party scripts run on Cloudflare’s edge, not the visitor’s browser
- Privacy: Better control over what data is shared with third parties
- Security: Reduced risk from third-party code vulnerabilities
- Simplified Management: Central dashboard to manage all third-party tools
Setting up Zaraz
Enable Zaraz in your Cloudflare dashboard:
- Select Zaraz from the side menu.
- If you have already added a tool before, select Tools Configuration > Third-party tools and click on Add new tool.
- Choose a tool from the tools catalog. Select Continue to confirm your selection.
- In Set up, configure the settings for your new tool. The information you need to enter will depend on the tool you choose. If you want to use any dynamic properties or variables, select the + sign in the drop-down menu next to the relevant field.
- In Actions setup the actions for your new tool. You should be able to select Pageviews, Events or E-Commerce 1.
- Select Save.
Cloudflare Zaraz has significantly improved my site’s performance while maintaining the functionality of my third-party tools. It’s a great example of how moving processing to the edge can benefit both users and developers.
Disclaimer: I’m not affiliated with Cloudflare, and this is not a sponsored post. I’m sharing my experience with Zaraz to help others improve their website performance.