Learn how to use Doppler with your Supabase applications

This guide will show you how to use Doppler with your Supabase applications by mounting your secrets as a temporary .env file using the Doppler CLI.


  • Have an existing Supabase project
  • The Doppler CLI is installed
  • The Supabase CLI is installed
  • doppler setup has been run for your application

Local Development

Web Apps

For web applications, you can run them locally using our typical CLI pattern. For example, you can start a typical NodeJS application like this:

doppler run -- npm start

For applications where using a .env file may be easier, you can use the Doppler CLI to mount your secrets as a .env file as well:

doppler run --mount ./path/to/.env --mount-format env -- npm start

Edge Functions

For Edge Functions, you can run them locally using .env mounts:

doppler run --mount ./supabase/.env.local -- supabase functions serve hello-world --env-file ./supabase/.env.local


When you're ready to deploy to production you can run the following command to sync your secrets from Doppler to Supabase (keep in mind this is a one-time operation that needs to be run again whenever your secrets change):

doppler run --mount ./supabase/.env -- supabase secrets set --env-file ./supabase/.env

You can double-check that your secrets were stored properly by running:

supabase secrets list