Skip to main content

Hi,

I just noticed this JavaScript console message:
Cannot load klaviyo.js multiple times for the same site. Skipping account "XXXXXX". Active account is "XXXXXX"

Does anyone know what it means and how I can resolve it? Thanks, -oo

Hello @Doubleo,

Thanks for sharing your question with the Klaviyo Community!

Typically this sort of console error arises when you have either duplicate Klaviyo.js present on your site all linked to the same account or if you happen to have multiple Klaviyo accounts accidentally integrated to the site. You can check to see if there this error is caused by a duplication in the Klaviyo javascript or by having multiple Klaviyo accounts by reviewing the Klaviyo.js snippets on your site through:

  1. Going to your website
  2. Viewing the Page Source or viewing the Inspector Tool
  3. Control + F (or Command + F on Mac)
  4. Search for the phrase Company_ID

If you were able to locate multiple instances of the same Klaviyo.js present on your site referencing the same Klaviyo Account ID, this may indicate that you have both the setting of Automatically add Klaviyo onsite javascript (recommended) enabled in your Shopify integration settings and have manually installed the Klaviyo.js snippet. In this case, we would recommend only one or the other; either allow Klaviyo to automatically inject the javascript or manually installing the javascript. To resolve this, I would suggest manually finding and removing this snippet from your theme file while only allow Klaviyo to automatically inject the Klaviyo javascript from the Shopify integration settings.

If searching through your site code returns multiple different results, this would indicate you have multiple Klaviyo accounts connected to this site. To resolve this, I would suggest taking the steps I’ve outlined in the Community post below to resolve this multi-account integration issue:

Have a great day!

David


Hi @david.to 

Thank you for the detailed explanation. I did check the site and yes, I see two instances of company_id, with the same account ID. They’re in very close proximity, but I guess still considered duplicates, right?

The interesting thing is that I did not manually install the Klaviyo.js snippet. I’m only using the “automatically add...” setting in Shopify integration settings. So I’m not sure what could be causing the duplicate. Any ideas?

Thanks,

–Onur


Hey @Doubleo,

Glad to hear the explanation helped you determine a duplication of your Klaviyo.js being present on your website! If you haven’t manually installed this duplicate code but rather only have the Automatically add Klaviyo onsite javascript (recommended) setting enabled; this concurrent code may have been created if you have ever disconnected your Shopify integration and reconnected the integration again. Each time you re-connect your Shopify integration with Klaviyo after having removed it with the  Automatically add Klaviyo onsite javascript (recommended) enabled, this would prompt Klaviyo to inject the code on your site again. 

To amend this, I would suggest reaching out to our Klaviyo Support Team to have them assist you in removing this accidentally injected set of Klaviyo.js. to get you back on track! 

David


Thanks @david.to. Support took care of it!

-oo


Reply