0

The local stack: CLI, Docker, Studio

Setupused in ~100% of apps

Everything so far has been a diagram. Two commands turn it into a database you can actually query on your own machine, for free, with no project to sign up for — and the first thing you will do once it's running is type the two most reassuring words in this entire course: `select version();`.

Core idea. `supabase init` writes a folder of source code — config, empty migrations, a seed script — that IS your backend, in git, before a single container exists. `supabase start` reads that folder and boots the whole cast from concept 2 as Docker containers on fixed local ports, with Studio as your window into all of it. The one fact that will save you real debugging time later: `supabase stop` only touches the containers; only `supabase db reset` touches your data.
Playground, this isn't a screenshot
$ supabase init
Docker containers
stopped
Your data
no database yet
1 / 6
Creates the supabase/ folder — this IS your backend, and it lives in git.

config.toml, an empty migrations/ folder, and seed.sql. No Docker has started yet and there is no database. This folder is source code: you commit it, review it, and your teammates get an identical backend from it.

Watch the two chips. Only stop and start move the Docker chip; only db reset throws away the Your data chip. Confusing those two — expecting a hand-typed row to survive db reset — is the most common day-one stumble.

↑ play a little first, then dig in