Works on my machine
Sign-up works perfectly on your laptop. On the , every sign-up fails.
This answers: Why does it work locally but not in production? No coding needed. 3 quick decisions.
- How a request travels
- Keys and secrets
- Debugging without panic
Checking your access…
Why does it work locally but not in production?
The most common cause is a missing . Your .env file exists only on your laptop; production has its own settings. Add the variable in your hosting dashboard, redeploy, and validate required variables at startup so a missing one fails the deploy instead of your users.
Breaks at Your server: Production has no API key
How it works
Your server: private
Every visitor's browser: public
Why AI tools write this bug
AI tools add new to your local as they build features, but they cannot add them to your hosting provider, so production quietly falls behind.
How to fix it
- Read the production logs for the exact error message.
3 more steps, and a prompt that checks your own app for this bug. Part of Pro.
UnlockCommon questions
- Should I commit my .env file so production gets it?
- No. It publishes your secrets to everyone with repository access, permanently, in git history.