Setup guide · Shopify
Add an install popup to Shopify — setup guide
Install InstantPWA on Shopify: exact snippet placement, published-site checks, phone testing and honest service-worker limitations.
Key takeaways
- Access to edit your Online Store theme.
- Use your own popup ID in the script.
- Verify the published address, not an editor preview.
- Treat install guidance and full PWA capabilities as separate checks.
Before you start
- Access to edit your Online Store theme.
- A published HTTPS site.
- An InstantPWA popup configured for that site address.
Step-by-step for Shopify
- Step 1Copy your popup’s code
Create your popup, save its published website address and copy the install code. Replace the example ID with your own.
<script src="https://instantpwa.com/api/public/embed.js" data-widget-id="YOUR_WIDGET_ID" defer></script> - Step 2Install and verify: step 1
Open Online Store → Themes in Shopify.
- Step 3Install and verify: step 2
Open the theme menu → Edit code, then layout/theme.liquid.
- Step 4Install and verify: step 3
Paste the snippet just before </body> and save.
- Step 5Install and verify: step 4
Open your published storefront, not checkout, and run the install check.
- Step 6Check what the home-screen icon actually does
Test Safari on iPhone and Chrome on Android. Open the installed shortcut and confirm the destination. A positive script check is not proof of offline caching or push permission.
Common Shopify gotchas
- Shopify CDN assets cannot register as a service worker on your storefront origin. Uploading sw.js to Files is not a complete PWA setup.
- An app-proxy route has its own path and scope; do not assume it provides a root-scoped worker.
- Use the storefront theme, not checkout customizations. Checkout is outside this installation workflow.
FAQ
Does the popup automatically provide offline support?
No. Offline support requires a service worker on the same origin and intentional caching. Check that separately from installing the snippet.
Why does the script check fail?
Check the popup ID, publish the code, clear caches and open the exact website address saved in InstantPWA. A script inside an iframe does not run as part of the main page.
Can visitors use an iPhone home-screen icon?
Safari offers Share → Add to Home Screen. Whether that launches a standalone PWA or a shortcut depends on the site configuration; test the launch on a real device.
Preview your install popup
Match your website’s branding before adding the snippet.