Preview Connection Errors

Common Error Types
CONNECTION_TIMEOUT
Symptom: Preview shows “Unable to connect to preview server” after waiting 5+ seconds. Common Causes:- Development server not running
- Server running on wrong port
- Firewall blocking connection
- Network connectivity issues
-
Start your development server
-
Check the server is running on the correct port
- Default port:
3456 - Verify in your terminal output:
Server running on http://localhost:3456 - Check project settings in Weaverse Studio for configured preview URL
- Default port:
-
Verify network connectivity
- Try opening the preview URL directly in your browser
- Check if localhost resolves:
ping localhost - Ensure no VPN/proxy interfering with local connections
-
Check firewall settings
- Allow Node.js through your firewall
- Temporarily disable firewall to test (macOS: System Settings → Network → Firewall)
- Whitelist port 3456 in your security software
NO_WEAVERSE_CONTENT
Symptom: The preview loads, but Studio shows “No Weaverse content on this page yet” with setup guidance — not a connection error. The URL responded; it just has no Weaverse sections for Studio to edit.This is a normal, recoverable state — not a broken preview. Studio stays connected on any page it can reach (including 404s and routes without Weaverse content) so it can tell you why there’s nothing to edit, instead of falsely reporting “Connection lost”. Requires
@weaverse/hydrogen 5.16.3+ in your theme.- No page or template has been created/assigned for this route yet
- The underlying Shopify resource (collection, product, article) doesn’t exist, or isn’t published to your Headless / Hydrogen sales channel — the storefront route then returns a 404 with no content to edit
- The route doesn’t render
<WeaverseHydrogenRoot /> - Missing or outdated
@weaverse/hydrogenpackage
-
Create or assign a page for this route
- Open the page selector in the Studio top bar and create/assign a page for the current URL
- Add at least one section, then Save
-
For a Shopify resource page, confirm the resource exists and is published
- In Shopify admin, verify the collection/product/article in the URL exists
- Publish it to your Headless (Hydrogen) sales channel — an unpublished resource returns a 404, so the storefront renders its not-found page with no Weaverse content
- Open the URL directly in your browser: a 404 there confirms the Shopify resource, not Weaverse, is missing
-
Verify the route renders Weaverse content
- The route loader should call
weaverse.loadPage()and the route should render<WeaverseHydrogenRoot /> - Ensure components are registered in
~/weaverse/components.ts(or~/app/weaverse/components.tsin the Pilot template) - Restart the dev server after adding new components
- The route loader should call
-
Confirm the page type is supported
- Supported types:
PRODUCT,COLLECTION,PAGE,BLOG,ARTICLE,INDEX,CUSTOM - Some routes (search, cart, account) use native Shopify components and aren’t Weaverse pages
- Supported types:
-
Update Weaverse if needed
@weaverse/hydrogen@latestinstalls v6, which requires Hydrogen 2026.10. To move a classic theme to v6, follow the v6 migration guide.
If you just created a page, make sure it uses the Weaverse page template and has sections configured. See the Rendering Weaverse Pages guide for complete implementation details.
INVALID_URL
Symptom: Preview shows “Invalid preview URL” immediately. Common Causes:- Malformed URL in project settings
- Missing protocol (http/https)
- Invalid characters in URL
- Localhost URL when expecting production
-
Check project preview URL settings
- Go to Project Settings in Weaverse Studio
- Verify preview URL format:
http://localhost:3456(development) - Ensure no trailing slash or extra characters
-
Validate URL format
- Must include protocol:
http://orhttps:// - Use
localhostnot127.0.0.1for local development - Check for typos in domain name
- Must include protocol:
-
Reset preview URL
- Delete current preview URL
- Enter fresh URL:
http://localhost:3456 - Save and refresh Studio
AUTH_REQUIRED
Symptom: Preview shows “Authentication required” or login prompt. Common Causes:- Password-protected development server
- Shopify authentication required
- Proxy/VPN requiring credentials
- Corporate network restrictions
-
Remove password protection temporarily
- Disable HTTP authentication in development
- Check for
.htaccessor auth middleware - Ensure dev server allows unauthenticated requests
-
Configure Shopify authentication
- Ensure valid session tokens
- Check Shopify app credentials
- Verify OAuth flow is working
-
Bypass network restrictions
- Test on different network (mobile hotspot)
- Whitelist localhost in corporate firewall
- Contact IT if on restricted network
CORS_ERROR
Symptom: Browser console shows CORS policy errors. Common Causes:- Missing CORS headers in development server
- Incorrect origin configuration
- Browser security restrictions
- Proxy/middleware blocking requests
-
Check the CSP for Studio’s sources
Studio embeds your storefront in an iframe and injects its bridge script from the
weaverseHostURL without a nonce. In design mode (the URL has aweaverseHostquery parameter), your CSP must include:frame-ancestors *- The Weaverse hosts (
*.weaverse.ioand theweaverseHostvalue) inscript-src,connect-src, andstyle-src 'unsafe-eval'inscript-src, so the bridge can rebuild schemaconditionfunctions
getWeaverseCsp(app/weaverse/csp.ts) sets all of these: -
Make sure
script-srclists every script origin Oncescript-srcis set, it replacesdefault-srcfor scripts. AscriptSrcthat lists onlyhttps://cdn.shopify.comblocks the Studio bridge as soon as the header is enforced, even if the Weaverse hosts are indefaultSrc. Look forviolates the following Content Security Policy directivein the console and add the blocked origin to the directive it names. On Hydrogen 2026.10 the theme builds the CSP header itself, since Hydrogen no longer shipscreateContentSecurityPolicy. See the Content Security Policy guide for the setup and a rollout checklist. -
Enable CORS for local development
-
Restart development server
- Stop server (Ctrl+C)
- Clear cache:
rm -rf .cache - Restart:
npm run dev
Advanced Troubleshooting
Check Browser Console
- Open browser DevTools (F12 or Cmd+Option+I)
- Go to Console tab
- Look for red error messages
- Copy error messages for support
Network Inspector
- Open DevTools → Network tab
- Refresh preview
- Look for failed requests (red status)
- Check request/response headers
- Note status codes (404, 500, etc.)
Verify RPC Communication
The preview uses PostMessage/RPC for Studio communication:Check the storefront runtimes in
window.__weaverses, not the Studio bridge. The bridge object is an internal implementation detail and does not expose a stable version field.Clear Studio Cache
- In Weaverse Studio, press Cmd+Shift+R (Mac) or Ctrl+Shift+R (Windows)
- This forces a hard refresh and clears cached preview state
Test with Different Browser
- Try Chrome, Firefox, Safari
- Disable browser extensions
- Use incognito/private mode
- Brave Browser Users: Disable “Shields” (ad blocker) for Studio domain
- Click the shield icon in the address bar
- Turn off “Shields” for
studio.weaverse.ioand your preview domain - Brave’s aggressive ad/tracker blocking can interfere with iframe communication
Getting Help
If you’ve tried all troubleshooting steps and still experiencing issues:-
Check System Status
- Visit status.weaverse.io for known issues
-
Community Support
- Join Weaverse Discord
- Search GitHub Discussions
-
Contact Support
- Email: support@weaverse.io
- Include:
- Error type from preview overlay
- Browser and OS version
- Node.js version (
node --version) - Package versions from
package.json - Console error messages (screenshots)
Prevention Tips
Development Best Practices
-
Always run dev server before opening Studio
-
Keep packages updated
-
Use recommended Node.js version
- Node.js 22.18+ or 24.11+ for the current Pilot template
- Check with
node --version
-
Monitor terminal output
- Watch for server errors
- Note the actual port being used
- Check for build warnings
Common Configuration
Recommendedvite.config.ts for preview:
- Preview URL:
http://localhost:3456 - Auto-reload: Enabled
- HTTPS: Disabled for local development
Related Resources
- Development Setup Guide
- Weaverse Configuration Reference
- Theme Development Guide
- Component Registration
Still having issues? The preview error overlay in Weaverse Studio provides real-time troubleshooting suggestions specific to your error type. Click the Documentation button in the error overlay for context-specific help.