Skip to content

Can Infinite Options scripts be deferred or loaded asynchronously?

Learn why Infinite Options scripts load on pages without option fields, such as in PageSpeed reports, and whether they can be deferred.

Why Infinite Options scripts load on every page

Section titled “Why Infinite Options scripts load on every page”

If you’ve reviewed your store’s Google Speed test PageSpeed Insights or Lighthouse report, you may notice that Infinite Options scripts appear on pages where you haven’t added any option fields, like your homepage or collection pages.

This is expected behavior, and it’s not specific to Infinite Options.

Shopify uses a system called ScriptTag to inject app scripts into your storefront. When an app is installed, Shopify controls where those scripts are loaded, and that’s sitewide by default.

Apps don’t have the ability to limit script injection to specific page templates, like product pages only. This is a Shopify platform constraint that applies to every app in the Shopify ecosystem.

Can the scripts be deferred or lazy-loaded on non-product pages?

Section titled “Can the scripts be deferred or lazy-loaded on non-product pages?”

No. Shopify requires app scripts to load fresh on each page request, which means standard browser caching and deferral techniques don’t apply.

What PageSpeed and Lighthouse are actually measuring

Section titled “What PageSpeed and Lighthouse are actually measuring”

Tools like Google PageSpeed Insights and Lighthouse measure your store against an idealized environment with no apps, fonts, analytics, or theme features present. Any app script will be flagged as a performance issue in these reports, even when everything is working normally. The warnings don’t necessarily reflect what your shoppers experience in real-world conditions.

Even large, well-optimized Shopify stores score lower on these tools for the same reason. A lower Lighthouse score caused by app scripts is expected and doesn’t mean something is broken.

If store speed is a priority, Shopify has guidance on improving overall performance here: https://help.shopify.com/en/manual/online-store/store-speed/improving-speed

For questions specific to how Infinite Options loads on your store, contact our support team.