Troubleshooting Klaviyo.js and site speed reports

Last updated at:

You will learn

Learn about Klaviyo.js (the JavaScript snippet that enables Active on Site tracking), its effect on site speed, and how to troubleshoot site speed performance. Klaviyo.js is injected automatically through many of our ecommerce integrations, and you can manually install it for other platforms. It enables Klaviyo sign-up forms to appear, and can allow you to track when customers are active on your site. 

Steps to troubleshoot site speed performance

  1. If you find that Klaviyo’s JavaScript is impacting your website’s performance (i.e., PageSpeed score) and it was automatically installed through an integration, you can try manually installing it instead
  2. For Shopify, we do not recommend installing Klaviyo.js manually, but instead recommend you enable Active on Site tracking through Klaviyo’s Shopify app embed. This bypasses the website’s native tag manager and can result in faster loading of Klaviyo’s JavaScript. 
  3. If you aren’t using Klaviyo sign-up forms, make sure all the forms in your Sign-up forms tab are set to Draft

Regardless of which installation method you use (e.g., through an ecommerce integration, or manually installed), Klaviyo’s JavaScript is loaded asynchronously. This means it will not block other aspects of your site from loading. However, Google’s PageSpeed Insights and other site speed reports may still flag it as a contributing factor in your site’s load times. 

Site speed and SEO are important to our customers, and Klaviyo is committed to minimizing the impact from our JavaScript. Learn how our engineers have optimized klaviyo.js recently. You will continue to see improvements as we release new updates. 

Additional resources

Was this article helpful?
18 out of 30 found this helpful