.env.local Site
# SENSITIVE: Keep this private! STRIPE_SECRET_KEY=sk_test_51Mz... # PUBLIC: Accessible by the browser NEXT_PUBLIC_ANALYTICS_ID=UA-123456789 Use code with caution.
Popular frameworks have built-in "loading orders." For instance, in , the hierarchy looks like this: .env.local (Highest priority) .env.development / .env.production .env (Lowest priority) .env.local
When a new teammate joins, they simply run cp .env.example .env.local and fill in their own credentials. # SENSITIVE: Keep this private
If you’ve ever accidentally pushed an API key to GitHub or struggled with different database URLs between your laptop and your teammate’s, .env.local is the solution you’re looking for. .env.local
This prevents .env.local , .env.development.local , and others from being tracked by Git.