Start from an Example
Jumpstart your development by cloning an Example project. This option is perfect if you're looking to explore what Supabase Modules can do in a fully functional app.
About this example project
This example project is based on a Next 14 application. More example projects coming soon.
1. Clone project and installing dependencies
Clone the repository using gh
CLI and then install the project's dependencies.
degit webscopeio/supabase-modules/apps/next my-app
cd supabase-modules
pnpm install
git init
2. Set environment variables
Create an .env
file to store your environment variables. The environment variables below are safe to share and use for local development.
# Since .env is gitignored, you can use .env.example to build a new `.env` file when you clone the repo.
# Keep this file up-to-date when you add new variables to \`.env\`.
# These examples are for development use only
NEXT_PUBLIC_SUPABASE_URL=http://127.0.0.1:54321
NEXT_PUBLIC_SUPABASE_ANON_KEY=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZS1kZW1vIiwicm9sZSI6ImFub24iLCJleHAiOjE5ODM4MTI5OTZ9.CRXP1A7WOeoJeXxjNni43kdQwgnWNReilDMblYTn_I0
To generate these environment variables you have to run Supabase locally first before development. Read more on Your Supabase Instance.
3. Start your development server.
Before proceeding
To work with a local Supabase Instance you need to run a database container with a running docker daemon. We recommend getting Docker. You can find instructions on Get Docker
pnpm db:start && pnpm dev
pnpm dev
If you are working with the Supabase Modules Workspace please refer to Workspace.
🎉 Congratulations!
You are done! See Installation for more information about the Modules. Remember that all modules are installed by default in this example.
Remember to run pnpm db:stop
to save resources once you are done working with your local Supabase Instance.