# More flexible Environment Variables in Edge Functions and Middleware

**Published:** May 24, 2023 | **Authors:** Javi Velasco, Gal Schlezinger

---

You now have more flexible access and improved limits for environment variables from [Edge Functions](https://vercel.com/docs/concepts/functions/edge-functions) and [Middleware](https://vercel.com/docs/concepts/functions/edge-middleware):

- The max environment variable size is now 64KB instead of 5KB, [same as Serverless Functions](https://vercel.com/docs/concepts/limits/overview#functions-comparison).
- Other than the [reserved names](https://vercel.com/docs/concepts/projects/environment-variables/reserved-environment-variables), there are no additional restrictions to name environment variables.
- Accessing `process.env` is no longer restricted to be statically analyzable. This means that, for example, you can now compute variable names such as `process.env[`${PREFIX}_SECRET`]`.

[Check out the documentation](https://vercel.com/docs/concepts/projects/environment-variables) to learn more.

---

📚 **More updates:** [View all changelog entries](/changelog/sitemap.md) | [Blog](/blog/sitemap.md)