Shopify Inbox App - Execution Time

Topic summary

Shopify Inbox chat widget is increasing JavaScript execution time, with PageSpeed showing about 238/135/64 ms total and two CDN scripts (shopifyChatV1Widget.js and sdk.js) contributing ~136 ms and ~103 ms. The store uses the Impulse theme, but the code isn’t visible in theme files.

Key cause: the widget injects scripts synchronously via App Embeds/App Proxy, so they don’t appear in theme.liquid. One reply notes chat scripts often add ~150–250 ms of blocking time.

Suggested mitigations:

  • Defer or delay loading: add defer or load on window.onload/first user interaction; enable “show after click/scroll” or a 2–3s delay in the Inbox widget settings.
  • Page‑specific loading: conditionally load only on key templates (e.g., home/contact) or toggle the app in Online Store > Customize > App Embeds per page.
  • Use Google Tag Manager (GTM) to fire the chat only after scroll, on click, or on selected URLs.
  • If scripts aren’t editable (injected by the app), follow an App Optimization guide, or ask theme/Shopify support for a deferral snippet. Some suggest lighter widgets or a script‑deferring tool (e.g., Website Speedy).

Status: No confirmed resolution; test changes via Online Store Speed report after each adjustment.

Summarized with AI on December 11. AI used: gpt-5.

Hi everyone

I’m struggling with site speed relating to this app - I’m seeing this in the “reduce javascript execution time” area

Shopify hosting 238 ms 135 ms 64 ms
…assets/shopifyCh….js (cdn.shopify.com) 136 ms 78 ms
…assets/sdk.js (cdn.shopify.com) 103 ms 57 ms

|

I understand from some other threads on this subject that loading needs to be deferred - however, I am using Impulse, and I don’t see anything in theme.liquid relating to the app. I also don’t see anything in sections or snippets that looks relevant.

Is anyone able to offer some fairly idiot proof guidance on how I might resolve this - I feel that a chat app is best UX but the speed impact makes it a hard choice?

Hi there, I’ve run into a similar problem with the Inbox widget slowing down load times. The chat widget injects two scripts from Shopify’s CDN and they’re loaded synchronously, so PageSpeed Insights flags them under “reduce JavaScript execution time”.

A couple of things you can try:

  • Defer loading: Move the <script src=".../shopifyChat.js"> and <script src=".../sdk.js"> tags to the bottom of your theme.liquid and add the defer attribute. This allows the page to render first and then initialize the chat widget. In Impulse you can insert them right above the closing </body> tag.

  • Conditional loading: If you don’t need the chat on every page, wrap the scripts in an {% if template.name == 'index' %} ... {% endif %} block or similar so they only load on pages where you actually want the chat.

  • Lazy load via settings: In Shopify Inbox there is an option to only show the chat after the customer clicks the chat icon. Enabling that delays initialization until the user interacts.

After making changes, run the Online Store Speed report again and see if the metrics improve. If you’re not comfortable editing theme code, contact the Impulse support team or Shopify support for help with a copy‑and‑paste snippet to defer the widget.

Hope that helps!

The code is not a part of the theme, so you can’t change it directly.
If you feel it seriously impacts your page speed you may follow this route:

1 Like

Defer the shopify-inbox script by loading it on window.onload or first user interaction to cut execution time. See Shopify’s dev docs for app performance best-practices.

Hii,

This issue usually happens because most chat apps load their JavaScript immediately, even before the page becomes interactive so they appear in PageSpeed under ‘Reduce JavaScript execution time’ just like you’re seeing. Even if you don’t see anything in theme.liquid, many chat apps inject their scripts automatically through App Embeds or App Proxy, so the code won’t show up in your theme files.
Because the script loads right away, it adds 150 - 250ms of JS blocking time.

Go to Online Store - Themes - Customize
Open App Embeds (left sidebar bottom)
Look for the chat app
Toggle it off on pages where you don’t need it (product pages, collection pages)
Many stores only keep chat on: Home, Contact, Checkout support pages
This reduces JS execution significantly.
Most chat tools have a setting called: Load on scroll, Load after delay, Load after interaction
Check your chat app dashboard - Settings - Widget Behavior.
Choosing a 2 - 3 second delay usually fixes the speed hit without hurting UX.

You can also load the chat app via Google Tag Manager and fire it only: after user scrolls, after a button click, on certain URLs
This keeps it completely out of the initial JS budget.

A lot of merchants switch to lighter chat widgets or speed optimization tools that handle script deferring for them. If you want the simplest solution, you can also try the Website Speedy App. It automatically delays non critical scripts, reduces JS/CS execution, and improves PageSpeed scores without editing any code.