App not rendering in ChatGPT or Claude
If your app shows a blank, stuck, or stale iframe after calling a tool, try these steps in order:1. Check your tunnel
If you’re using ngrok or a similar tunnel to expose your local server:- Verify the tunnel is running and pointing to the correct port
- Make sure the tunnel protocol matches: use
ngrok http 8000, notngrok http https://localhost:8000 - Check the tunnel URL in your host’s MCP server settings matches the active tunnel
2. Check your dev server is running
Make suresunpeak dev is running and the MCP server started successfully. You should see:
port 8000 was in use), update your tunnel and host configuration to match.
3. Restart the dev server
4. Refresh or re-add the MCP server in the host
Most issues are resolved by refreshing the MCP server connection. In the host’s settings, click refresh on the MCP server entry, or remove and re-add it: ChatGPT: Settings > MCP Servers > Refresh (or Remove > Add again with your tunnel URL) Claude: Settings > MCP Servers > Refresh (or Remove > Add again with your tunnel URL)5. Hard refresh the host and open a new chat
Both ChatGPT and Claude cache MCP server connections and resource content aggressively.- Hard refresh the page (
Cmd+Shift+R/Ctrl+Shift+R) - Open a new chat (cached iframes persist within the same conversation)
- Re-trigger the tool call
Port conflicts
sunpeak uses several ports during development:| Port | Purpose | Override |
|---|---|---|
| 3000 | Inspector UI | sunpeak dev --port 3001 |
| 8000 | MCP server (tunnel target) | Automatic fallback |
| 24679 | Vite HMR WebSocket | SUNPEAK_HMR_PORT env var |
| 24680 | Sandbox iframe server | SUNPEAK_SANDBOX_PORT env var |
port 8000 was in use.
HTTPS / ngrok issues
If you seeReceived HTTPS request on sandbox server, your tunnel is sending HTTPS traffic to an HTTP upstream. Fix:
Build errors with sunpeak dev --prod-resources
If --prod-resources mode fails, the built HTML may be stale or missing:
Blank page in the inspector
If the inspector loads but the resource iframe is blank:- Check the browser console for errors (especially CSP or CORS issues)
- Make sure your resource component is the default export from
src/resources/{name}/{name}.tsx - Verify you have at least one simulation in
tests/simulations/that references your tool