Skip to main content

Live preview

Every project has a live preview — a real, running version of your app that sits next to the chat and updates as the AI makes changes. It's the fastest way to see exactly what you're building.

What the preview shows​

The preview is your actual app, not a mockup, and not a static render — it's a full run of the app, server routes and server-side rendering included, with your project's database connected. You can:

  • Click around — navigate between pages, open menus, and try interactions.
  • Fill in forms and test flows as a real user would.
  • Work with real data — the preview uses the database of the project's selected environment, and its built copy also uses that environment's file storage (see The built lane and the live lane). On a project with only production, that's your live app's data, so rows and files you create in the preview are real. On a project with environments, pick one such as staging in the top bar to work on its copy instead.
  • See changes instantly — as the AI edits your app, the preview refreshes to reflect the latest version.
Sign-in and payments work differently in the preview

Sign-in emails, Google sign-in and SSO are switched off in both lanes of the preview — the built copy and the live dev server — on purpose: the preview is never given the keys they need. Test them on a published app: production, or one of your environments once you've turned them on there — Send email from this environment in Cloud → Email, or Allow in this environment for Google and SSO (see Differences from production). Hovering over the info icon in the preview toolbar tells you the same thing.

The preview also keeps its own sign-in sessions, separate from the published app's, so being signed in on one doesn't sign you in on the other. Email and password sign-in does work in the preview; only the steps that send an email, such as verification or a password reset, don't.

Checkouts in the preview always run in the Stripe sandbox. When your store is live and the preview is on production's data, orders placed in the preview aren't delivered to your app, so a test order can't land in your live data. See Stripe payments.

Jumping to a page​

A path bar above the preview lists your app's pages, worked out from its route files. Search that list, or type any path yourself, and the preview goes there — handy for reaching a screen that's several clicks deep. There's a refresh button next to it.

One quirk worth knowing: a route with a parameter in it (something like /orders/:id) can't be opened by clicking, because :id isn't a real address. Clicking it reopens the search box so you can type a concrete path, such as /orders/42.

Controls​

Once the preview is running, the toolbar gives you:

  • Restart preview — restart the preview.
  • Stop preview — shut the session down.
  • Undo and Version history — step back one change, or restore an earlier version of the project.

Before it's running you get a refresh button instead, which retries creating the session. If the preview fails to start, the pane retries on its own up to five times. It shows Starting preview… during each attempt and waits longer between attempts, from 5 seconds up to a minute. If every attempt fails, it stops on No preview available, and the refresh button starts a fresh round. Each failed attempt is listed under Logs → Raw.

There's also a named warning for one confusing failure: if your app puts itself into a reload loop, the preview says so — "This preview keeps reloading itself" — pauses automatic refreshes, and points out that the loop is in the project's own code. A spinning preview gets explained instead of staying a mystery. The warning's Try again button resumes automatic refreshes.

Sessions start early, and don't run forever​

  • The first start is the slow one. A preview begins provisioning the moment a project is created. Every project keeps its own preview machine between sessions, and that very first start creates the machine and installs your app's dependencies, so a brand-new project may show Starting preview… for a while. Later opens reuse the machine and only catch up on what changed. If the machine has been reclaimed in the meantime, a fresh one is created, with the same slower start.
  • It stays up while you have the project open. While the project is open in a Studio tab, the Studio checks in every few minutes, which keeps the preview alive. A single session lasts at most 8 hours, after which the pane starts a new one. Close the tab and the preview is released after about 30 minutes without activity. Reopening the project starts it again — there's nothing to restore by hand.
  • The preview limit counts projects, not tabs. One person can only have so many previews running at once, and two tabs on the same project share one preview. At the limit, another project's live session won't start. The pane keeps showing that project's built copy if it has one, or No preview available if it doesn't, and Logs → Raw shows "Maximum active previews (N) reached", where N is your limit. Close the Studio tabs of projects you aren't using (their previews are released after about 30 minutes), then press the toolbar's refresh button. Publish has to start a preview when none is running, so it runs into the same limit.
  • Deleting a project shuts its preview down and revokes its link.

The built lane and the live lane​

After each successful change, Berrybell also builds a deployed copy of your app for preview. When one exists, the pane shows that by default — it paints faster than the live dev server — marked with a Published chip you can click to open it in a new tab. A new project usually gets its first built copy automatically, as soon as the preview started when you created it is up. If that start fails, or you were at your preview limit, the first built copy arrives with your first change.

Despite the chip, that copy is still private to you. It is not your published app.

Choosing the select element tool switches the pane to the live dev session, which is the lane that element selection and in-place editing need. While you're pinned there a Live chip appears; clicking it takes you back to the built lane.

One caveat: the built lane can be a pre-rendered static build with no server running behind it. If a server route or a form works everywhere except there, try it on the live lane.

If your app saves uploaded files, test that on the built lane or on the published app. The built lane uses the selected environment's file storage — production's, on a project with only production — so files uploaded there are stored for real. The live lane, and a pre-rendered static build, have no storage connected.

On a project with more than one environment​

On a project with environments, the preview runs on whichever environment is selected in the environment switch in the top bar, beside the project name. The pane has no switch of its own. The selection belongs to the project, so changing it changes it for every tab and every teammate, and choosing production asks you to confirm first.

  • The chips name the environment. The built lane's chip reads Preview · staging and the live lane's Live · staging, with your environment's name in place of staging.
  • The built lane only shows a build made on the selected environment's data. Right after a switch, the pane shows the live session until your next change produces a new build.

Notices above the preview say what's going on:

  • "Switching the preview to staging…" while a switch is in progress.
  • "staging was deleted, so the preview has no database. Choose an environment."
  • "staging isn't ready, so the preview has no database until it is. Wait, or choose another environment."
  • "The preview wasn't deployed because …", followed by the reason, when a built copy was skipped — for example because no environment is selected, or the selected one is still being set up.
  • A note when a teammate switches the project, naming them and the environment: "… switched this project to staging. The preview and new changes use it now."

While production is selected, a lasting Preview is using production data chip stays above the preview: what you and the AI do in the preview then changes your live app's data.

Using the preview while you build​

  • Point at what you see. Reference elements in the preview when you chat: "make the button in the preview larger" or "the second card's text is cut off."
  • Test as you go. After each change, try it in the preview before moving on.
  • Catch issues early. If something looks wrong or breaks, describe it in the chat and the AI will work on a fix.

Preview vs. published​

The preview is a work-in-progress view, visible to you as you build. It is not your public app. Changes to your app only reach the public when you Publish. This means you can experiment freely — try bold changes, undo them, iterate — without changing what your visitors see. Data is the exception: the preview works on the selected environment's data, which on a project with only production is your live app's (see What the preview shows).

On a project with environments, each environment you created also has its own published address. It's updated only when you publish to that environment, and it runs on that environment's own database.

Live previewPublished app
Who sees itYou (and your workspace)Anyone with the URL
UpdatesInstantly, as you buildOnly when you publish
PurposeBuild and testShare with the world

Preview links are gated, not merely unlisted: opening one without being signed in to the workspace that owns the project gets you a sign-in prompt, not your app.

Next steps​