--- description: | How to use environment variables in Fresh, including public variables that are inlined into island bundles. --- Environment variables in Deno are typically read via `Deno.env.get()` or `process.env.*` calls or via an `.env` file if the `--env-file` flag is used, see [how to use Environment Variables in Deno](https://docs.deno.com/runtime/reference/env_variables/). On top of that Fresh automatically inlines all environment variables whose names start with `FRESH_PUBLIC_` during bundling of [islands](/docs/concepts/islands). > [info]: This inlining step occurs when building the app (`deno task build`). > Environment variables inside islands cannot be read at runtime. Example: ```sh Terminal $ FRESH_PUBLIC_FOO=bar deno task dev ``` ```tsx export function MyIsland() { const value = Deno.env.get("FRESH_PUBLIC_FOO"); return