Preview of site doesnt load, stuck on spinner

Hi, I’m trying to use v0’s live preview to speed up iteration on my project, but the preview pane next to the chat just shows a spinner. However:

- The agent’s chat claims the app has loaded and provides screenshots

- The “preview” and “production deployment” buttons both load the app fine

- I’ve tried refresh, hard reload, new sessions — no change

**Console errors (DevTools → Console):**

When I check the preview pane’s console, I see repeated:

- `GET Unauthorized - v0 by Vercel - v0 by Vercel … 502 (Bad Gateway)` — the preview VM itself returning 502

- `WebSocket connection to wss://sb-13ck1labwwpm.vercel.run/ failed` (reconnecting 1000ms, 2000ms, 4000ms…)

This tells me the preview sandbox VM has crashed or failed to provision, since production works fine. The agent’s screenshot seems to fire on an iframe load event even when the 502 error page loads, which is why it claims success.

**My setup:**

- Project: Tauri + React

-Github linked

- OS: macOS

- Browser: Chrome

- The app code itself is fine (proven by prod/preview button working)

Is this a known v0 sandbox infra issue, or is there a way to force re-provision a fresh VM? I want to take advantage of quick editing but right now I’m stuck in an edit → rebuild loop.

Hi Jenna,

Since the preview and production deployment buttons load but the in-chat preview iframe stays on a spinner, I’d treat this as separate from the deployed app first. v0’s in-chat preview runs from the chat’s sandbox/dev server, while the deployed preview/production URLs run on deployment infrastructure.

I’d check the v0 Console panel for the sandbox logs and look for the first dev-server error before the repeated 502 / WebSocket reconnects. For a Tauri + React app, the useful things to confirm are:

cat package.json

and whether the sandbox is starting the expected web dev command, usually something like:

npm run dev
# or
pnpm dev

If the dev server is crashing, the preview iframe can just keep reconnecting even though the deployed build works.

To separate a stuck sandbox from an app issue, I’d also try creating a fresh v0 chat/fork from the same GitHub repo. v0 sandboxes are per-chat, so if a fresh chat works, the original chat’s sandbox is likely wedged. If the fresh chat also fails with the same 502, then I’d look for a dev-server/start-command mismatch or a Tauri-specific assumption in the app that does not run cleanly in the browser preview.

One non-sensitive detail that would help: what is the first error shown in the v0 Console/Logs panel before the WebSocket reconnect loop starts?

Hi, thanks for the reply! I know this isnt super helpful but the iframe is loading now. Attached are my console logs. I didnt make any foundational project changes that would contribute to this so it must have been something on the backend. I guess we can close this out, thanks again

15:41:21.729Z**[SERVER]**

Installing dependencies...

15:41:21.848Z**[SERVER]**

Installing dependencies with npm@11.11.0...

15:41:23.843Z**[SERVER]**

npm warn deprecated whatwg-encoding@3.1.1: Use @exodus/bytes instead for a more spec-conformant and faster implementation

15:41:26.897Z**[SERVER]**

added 441 packages, and audited 442 packages in 5s

15:41:26.897Z**[SERVER]**

181 packages are looking for funding
run `npm fund` for details

15:41:26.898Z**[SERVER]**

found 0 vulnerabilities

15:41:28.711Z**[SERVER]**

> worldbuilder@0.1.0 dev
> vite

15:41:28.986Z**[SERVER]**

VITE v6.4.3 ready in 204 ms

15:41:28.986Z**[SERVER]**

➜ Local: http://localhost:1420/
➜ Network: use --host to expose

15:42:16.006Z**[SERVER]**

7:42:16 PM [vite] (client) hmr update /src/styles.css