In short.
Lovable’s Database documentation helps app builders and developers manage PostgreSQL data, but its editing tools operate on the database used by the published app. Beginners get instructions for browsing records, collecting form submissions and requesting tables through chat. Developers get details about Drizzle migrations, Git integration, extension restrictions and failure behavior. The most consequential points are that direct SQL bypasses migration history, a schema change can apply other pending migrations, and a timeout does not establish whether a change succeeded. Pricing, licensing terms and measured performance are unknown from this page; no behavior was executed or tested.
Researched and written by an AI model and checked by a second AI model. How it works
Covers the complete selected page at [https://docs.lovable.dev/features/database.md], including table operations, forms, draft restrictions, hosting location, SQL, migration mechanics, extensions and all FAQ material. The direct-edit warnings, pending-migration behavior, transaction differences, timeout and cancellation notices, and recovery limitations are included. Linked documentation, images as independent evidence, external integration procedures, pricing and legal terms are excluded. No resource behavior was executed or tested.
The overview
Identity
This is Lovable’s Database feature guide at [https://docs.lovable.dev/features/database.md]. It explains the built-in Cloud backend’s managed PostgreSQL database and the tools available through project chat and the Database view.
The page combines introductory explanations of tables, rows and columns with operational details about SQL, migrations, database access and supported extensions.
Assessment
The guide is useful for deciding whether Lovable’s managed database workflow fits an app and for understanding the consequences of changing an existing project. It provides concrete navigation, editing instructions and failure cases rather than only describing features.
Its strongest developer material concerns migration behavior: approving the SQL shown for a requested change does not mean that only that migration will run. Its main beginner-facing caution is equally practical: changing or deleting records can immediately affect the published app. These are documented behaviors, without independent execution evidence.
Users
App builders who need contact forms, client records, orders or messages can follow the chat and table-editing instructions without writing SQL. The spreadsheet comparison makes the basic storage model accessible.
Developers maintaining a published Lovable app get more specialized guidance on schema history, generated type definitions, Git-supplied migrations and PostgreSQL extensions. Teams handling sensitive form submissions should note that anyone with project edit access can read the entire submissions table.
Capabilities
The Database view lists tables with approximate row counts and displays database views as read-only results. Table tools support column filters, in-place value editing, adding rows, editing full rows, deletion and CSV export. Full-row editing requires a single primary key. CSV export includes every row matching the current filters across all pages.
Pagination offers 10, 25, 50 or 100 rows. Refresh reloads data; the view does not update live. There is no import button: file imports are requested by attaching a file in project chat. The Manage menu opens jobs, the SQL editor, edge functions, backups, access policies and settings.
The SQL editor offers table and column autocomplete, tabular results and error messages. It requests confirmation for statements such as DELETE, DROP, TRUNCATE, ALTER and UPDATE.
Supported extensions are pg_cron, pg_net, pg_trgm, vector, btree_gist, btree_gin, unaccent, fuzzystrmatch, postgis and pgmq, covering scheduling, HTTP requests, search, indexes, spatial data and queues. The page also lists plpgsql, pg_graphql, pg_stat_statements, pgcrypto, uuid-ossp and pgsodium as preinstalled.
Using it
Requirements
Opening the Database view and changing records requires edit access to a Lovable project. A project without a database offers an Enable button. Enabling it also adds user accounts and file storage because those services run together.
Database creation must happen in the main project version rather than inside a draft. The hosting region is fixed at creation and cannot subsequently be changed, so location requirements need resolving beforehand. Plan eligibility, account requirements and infrastructure quotas are not specified on this page.
Mechanism
When chat requests change tables, columns or access rules, Lovable updates the database and the app’s type definitions. Current projects record structural changes as SQL files under drizzle/migrations/. Earlier projects use supabase/migrations/, and those older files remain after a move to Drizzle. Lovable maintains drizzle/schema.ts, drizzle.config.ts and the surrounding Drizzle folder.
For Drizzle projects, the next schema change can apply all pending migrations, including files previously added through Git. Pushing a file alone does not apply it. A file must appear in drizzle/migrations/meta/_journal.json, with a date later than the last applied migration. Files without journal entries are not applied; older-dated entries can be skipped without an error or another attempt.
The documented Drizzle migration run applies pending changes together: a statement failure rolls back the run. Migration SQL containing BEGIN, COMMIT or ROLLBACK is rejected, and some statements, including CREATE INDEX CONCURRENTLY, cannot run inside the transaction. Runs are serialized. Changed tables remain locked until the run finishes, making reads and writes wait. For the earlier Supabase setup, the guide directs readers to support before relying on full rollback.
Applied migration records are separate from source files. Drizzle records a SHA-256 hash of each file as executed; the earlier setup records a version and name without a hash. Editing a file later does not alter the database changes already applied. Migration connections have schema and storage-policy privileges, while app code uses different connections.
Setup
In the main project, describe the information the app needs to store in project chat, or use Enable when the Database view offers it. After tables exist, open More → Database and select a table to inspect its records.
Use Manage → Settings to see the hosting region and the project’s PostgreSQL version. Use Manage → SQL editor for direct queries. The page links to separate instructions for choosing a region, backups, capacity and access policies; those linked instructions are outside this guide’s assessed scope.
A new draft usually receives its own copy of the database structure populated with example data, and its Database view is disabled. Accepting the draft brings its structural changes into the project database.
Example
The guide’s client-management example asks Lovable to store client names, email addresses, phone numbers and notes, plus deals associated with clients, values, stages and expected closing dates. This illustrates describing a data model in ordinary language before inspecting its tables in the Database view.
For a contact or booking form, the guide says Lovable creates a submissions table and configures visitors to submit without reading, changing or deleting submissions. Project editors can read the table. Email delivery can also be requested.
A form can instead deliver to an existing CRM or another destination. In that case, Lovable does not automatically create a table, but offers to retain a copy to protect against failed delivery. These are documented examples; no form, database or delivery integration was built or run.
Assessment & evidence
Limitations
Record edits target the database used by the published app, and row deletion cannot be undone through the table interface. A new migration may reverse a structural change, but cannot recover deleted data without another copy. The guide does not promise a restore point for every migration or publish a maximum migration size.
Direct SQL is neither saved as a migration file nor entered into migration history. Multiple statements submitted through the SQL editor are not guaranteed to share one transaction on most projects, so earlier statements can remain applied after a later error. Cancel stops the browser’s wait while the query continues in the database.
Timeouts can occur even when a migration is subsequently applied, and some execution paths retry automatically. Repeating a request without checking the database can repeat a change. Recording SQL already executed in the editor requires support-assisted reconciliation rather than running it again.
Built-in databases cannot move regions or be shared between projects. Unsupported extensions are rejected through chat, the SQL editor, the API and MCP; the API reports 403 with unsupported_extension. Already-installed extensions keep working. These constraints require checking a project’s needs before committing to the built-in backend.
Reasoning
The documented migration history and automatic type updates support preferring chat for routine schema changes. Direct SQL offers more immediate control, but creates a gap between database state and migration files. That trade-off follows from the described mechanisms; it is not a measured comparison.
Lovable normally refuses dropping or renaming tables or columns, changing column types, and adding required columns without defaults, instead using additive changes. Agent permissions can allow backward-incompatible migrations either after approval or automatically.
Those permissions do not isolate a requested change from earlier pending migrations. A reasonable operational inference is to inspect pending files and journal dates before requesting another schema change, even when the interface asks for approval of the newly shown SQL.
Alternatives
For several apps that need one database, the page identifies a shared external Supabase project as an alternative to the isolated built-in databases. It also says the built-in extension restrictions do not apply to projects using their own Supabase project.
That route has a documented complication: Lovable projects sharing one Supabase project can overwrite each other’s secrets. The linked integration guide at [https://docs.lovable.dev/integrations/supabase.md] was not assessed, so its configuration requirements and costs remain unknown.
For collecting submissions without maintaining an app table, the guide describes sending forms directly to a CRM or another named service, with an optional stored copy.
Evidence
The evidence is the complete first-party Database documentation page at [https://docs.lovable.dev/features/database.md], including its warnings, extension list and FAQ. It supports specific descriptions of interface operations and migration behavior.
These are publisher-documented claims. No commands, SQL, migrations, imports, exports or app journeys were executed. Performance, security enforcement, reliability and recovery outcomes were not independently assessed. Linked pages supply references for further reading, without additional findings here.
Access & freshness
Costs
The page provides no subscription prices, database usage rates, included allowances or charges for storage, backups, resizing or extensions. Total operating cost and paid-plan requirements are unknown.
It describes high-load notices and links to instance resizing and additional storage, but supplies no capacity figures or performance measurements from which to estimate a suitable configuration.
Rights
Licensing and redistribution rights for this documentation, and platform terms covering generated code or stored data, are unknown from this page. Drizzle is described as open source, but its specific license is not supplied.
CSV and database export are documented capabilities. The page does not establish commercial-use permissions or ownership terms through those export features.
Freshness
The documentation was captured on 24 November 2026 at 16:47:38.489 UTC. It contains no publication date, last-updated date or fixed PostgreSQL or Drizzle version.
The distinction between drizzle/migrations/ and supabase/migrations/ makes the project’s actual configuration consequential. Settings can display a project’s PostgreSQL version, but no specific project configuration or service behavior beyond the captured documentation is established.
Actions
Before enabling a database, establish the required region, whether multiple apps must share data, and whether the supported extensions cover the app’s needs. Obtain pricing and capacity information separately, since this page does not provide it.
Before editing a published project, inspect project-editor access and relevant row policies. Before requesting a schema change, check the migration layout, pending files and journal dates. Use the documented approval setting when backward-incompatible changes need review.
After a timeout, error or browser cancellation, check actual database state before retrying. Confirm recovery options with support before destructive work, and seek reconciliation help when direct SQL needs to be represented in migration history.
