#env varibles

5 messages · Page 1 of 1 (latest)

jolly wren
#

hello. somehow, my nextjs app that I deployed on railway cant access environment variables in nextjs16 instrumentation-client

I even passed the keys with the .toml file but i cant acsess it.

#

to do some workaround i had to do a route

#

i dont know why

idle ploverBOT
#

New reply sent from Central Station thread:

I would highly suggest not using
NEXT_PUBLIC_*
variables for backend.
NEXT_PUBLIC_*
variables are exposed to the public internet.
I would recommend using just
POSTHOG_KEY
and
POSTHOG_HOST
instead.

You're seeing this because this thread has been automatically linked to the Central Station thread.

jolly wren
#

POSTHOG keys are meant to be public. Their team secures them. I cant access the variable.