Env Variables Not Working When Opening v0 Chat in External Window

I’m encountering an issue where my environment variables stop working whenever I open a v0 chat in an external window.

This behavior is consistent and seems isolated to external chat windows. Everything works as expected within the embedded chat interface.

Did you know there’s another category dedicated to v0 topics? A human should be here soon to help, but the answer may already be available even faster in one of these other posts.

Our docs are a great place to start.

We also have a walkthrough to help guide your workflow.

And these recordings can give you a look at v0 features and strategies in action shown by our Community:

https://community.vercel.com/tags/c/events/42/v0

Hi @lance-6041, welcome to the Vercel Community!

Environment variables are not present in the Open in new window feature for security reasons. If you want to share your application externally, you can deploy it and then share the deployed URL instead.

I hope this was helpful.

Why can’t environment variables be stored on the server, except for those prefixed with NEXT_?