The Turso CLI lets you manage databases, tokens, and groups from the terminal. You don't need it for this chapter — everything is done through the web dashboard — but it's useful for scripting and automation later.
If you have Homebrew:
brew install tursodatabase/tap/turso
If you don't have Homebrew, use curl instead:
curl -sSfL https://get.tur.so/install.sh | bash
Restart VS Code so the terminal picks up the new command.
Verify it worked:
turso --version
You should see a version number. Now log in:
turso auth login
This opens your browser — confirm the login and come back to the terminal.

# Create a group in a specific region
turso group create my-group --location aws-us-east-1
# Create a database in that group
turso db create my-db --group my-group
# Get the database URL
turso db show my-db --url
# Create an auth token
turso db tokens create my-db
# Open a SQL shell
turso db shell my-db