Database & Data Storage

Store and manage data in your web applications.

Steps

  1. For websites: you usually don’t need a database (forms can use a form backend).
  2. For apps: choose a database provider (Supabase Postgres is the easiest) and create a project.
  3. Copy your connection string (e.g. DATABASE_URL) and add it as an environment variable in your host (Vercel/Render/etc).
  4. Describe your data model in the prompt (e.g., "users have posts, posts have comments").
  5. The AI generates schema + CRUD code to match your chosen stack.
  6. If you self-host, ensure your DB allows connections from your hosting provider (IP allowlists if required).

Copy/paste prompts

Use these in the editor chat after you’ve gotten the required link/key/embed code.

App with data model

/guides/database
Create a blog platform where users can write posts with titles, content, and tags. Posts can have comments from other users. Include a feed showing recent posts.

Connect Supabase (Postgres)

/guides/database
I am using Supabase Postgres. Use DATABASE_URL from env vars for all DB connections. Add migrations and a simple seed script.

Add new data type

/guides/database
Add a "categories" feature. Users should be able to create categories and assign posts to them. Show a category filter on the feed.

Data relationships

/guides/database
Add a following system. Users can follow other users and see posts from people they follow in a personalized feed.

Links