# The Preview works but the live site doesn't

**What you see:** Everything works on the Preview link, but the live address fails or behaves differently.

**Why it happens:** Preview and Production have separate settings. Usually an environment variable exists for one and not the other.

## How to fix it

1. Ask your agent to compare the environment variable names in both (`vercel env ls`), never the values.
2. Add the missing one in Vercel yourself, then redeploy.

## Message for your agent

```text
My Preview works but Production doesn't. Compare the environment variable names for Preview and Production with `vercel env ls`, read the runtime logs, and tell me what's different.
```

**How to prevent it:** When you add a variable, tick both Production and Preview.

---
Source: [Agentic Makers](https://agenticmakers.app/en/help/preview-works-live-doesnt) · License: CC BY 4.0
