Database
An organised system for storing, querying, and managing structured data that persists beyond a single request.
A database is a persistent, organised store of structured data. Unlike variables in memory that disappear when a program ends, databases save data to disk so it survives between requests, server restarts, and deployments.
The two main categories are: relational databases (PostgreSQL, MySQL, SQLite) which organise data into tables with rows and columns, and non-relational or NoSQL databases (MongoDB, Redis, DynamoDB) which use documents, key-value pairs, or other formats. PostgreSQL via Supabase has become a popular choice in vibe coding stacks because the managed hosting, built-in auth, and real-time features remove most of the infrastructure complexity.
Key concepts: schema (the structure of your tables), queries (reading data), mutations (writing/updating/deleting), indexes (making queries fast), and migrations (evolving your schema over time without losing data).