🔋 Supabase

Remote database setup

Supabase Setup

  1. Sign up for a Supabase account
  2. Create a new project
  3. Make sure to save your database password
  4. In your project dashboard, go to Settings > API
  5. Copy your Project URL with anon public and service_role secret API keys.

You'll need to add these to your environment variables: (.env file)

NEXT_PUBLIC_SUPABASE_URL=your_project_url
NEXT_PUBLIC_SUPABASE_ANON_KEY=your_anon_public_api_key
SUPABASE_SERVICE_ROLE_KEY=your_service_role_key

Login to Supabase

npx supabase login

Enter this command and select the project you want to link

npx supabase link

Push your schema

You will be prompted to enter your Database password

npx supabase db push

Well done! You have successfully setup your Supabase database.