Secrets not working in nextjs

I was able to get secrets to work in python after a delay, but they aren’t working in Javascript, specifically nextjs.

I think I answered a next js secret problem before. You can’t really get secrets to work, because quote google:

Next. js is a front-end framework

Anything front-end can not access secrets because any users would be able to access it.


Yeah, this is a well-known limitation, but perhaps it’s possible using getServerSideProps?

You shouldn’t put secrets in front-end code. Perhaps create a backend with Python or Node.js?

1 Like

If you used it like that it would not be “secret” anymore.


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.