Squarespace works well with StoreRocket, but there's one gotcha you need to know about. This guide covers the install process and the fix.
Adding the embed code
Go to your Widget Install page in StoreRocket and copy the embed code
In Squarespace, open the page where you want the store locator
Add a Code Block (click the + button, search for "Code")
Paste the StoreRocket embed code
Make sure Display Source is unchecked
Click Save
Your store locator should appear on the page.
The Squarespace Ajax loading issue
Squarespace uses Ajax page transitions by default. This means when visitors click between pages, Squarespace doesn't do a full page reload. It loads content dynamically instead.
The problem: if your store locator page is loaded via Ajax (visitor clicks a link to it), the StoreRocket script might not execute. The widget won't appear.
Fix: Disable Ajax loading in Squarespace:
Go to Design > Site Styles in your Squarespace admin
Find the Ajax Loading toggle
Turn it OFF
Save
This forces Squarespace to do full page reloads, which ensures the StoreRocket script runs every time.
If you don't want to disable Ajax globally, an alternative is to link directly to the store locator page (full URL, not a relative link) so Squarespace does a full load for that page.
Making the widget full width
By default, Squarespace content blocks have padding on the sides. To make your store locator stretch full width:
In the Squarespace editor, click on the section containing your Code Block
Go to section settings
Set Content Width to Full or Full Bleed
Troubleshooting
Widget not appearing at all
Make sure you're using a Code Block, not a Markdown Block or Text Block. Only Code Blocks execute JavaScript.
Widget appears briefly then disappears
This is the Ajax loading issue. Disable Ajax loading as described above.
Widget shows but map is blank
Your map provider isn't set up. Go to Map Provider settings and add your Google Maps API key or Mapbox token.
Questions? Hit us up on live chat.