/Wiki/sources/honojs__hono/2026/https-hono-dev-llms-full-txt-load-env-when-local-5141a6e05b26-load-env-when-local-development-s0392-c0000.md
Load env when local development (1) - hono-docs
Load env when local development (1) Source evidence: /Sources/raw/honojs hono/honojs hono.md Canonical citation: https://hono.dev/llms full.txt load env when...
Load env when local development (1)
Source evidence: /Sources/raw/honojshono/honojshono.md Canonical citation: https://hono.dev/llms-full.txt#load-env-when-local-development
Summary
To configure the environment variables for local development, create a .dev.vars file or a .env file in the root directory of the project. These files should be formatted using the [dotenv](https://hexdocs.pm/dotenvy/dotenv-file-form...
Content
To configure the environment variables for local development, create a .dev.vars file or a .env file in the root directory of the project.
These files should be formatted using the dotenv syntax. For example:
SECRET_KEY=value
API_TOKEN=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9For more about this section you can find in the Cloudflare documentation: https://developers.cloudflare.com/workers/wrangler/configuration/#secrets
Then we use the c.env.* to get the environment variables in our code.