Cloud, Database & Supabase questions
Tables, queries, RLS, storage and how Lovable Cloud relates to Supabase.
What is Lovable Cloud?
Lovable Cloud is a Supabase backend (Postgres database, authentication, storage, edge functions) that Lovable provisions and manages for your project automatically, with no separate account or dashboard needed.
Last checked 31 Aug 2026
When should I use Lovable Cloud?
Use Lovable Cloud for most new projects needing a backend — it's the fastest path with no separate account; connect your own Supabase project instead if you already have one, need direct dashboard access, or must integrate with existing Supabase infrastructure.
Last checked 31 Aug 2026
How do I connect Supabase to Lovable?
In your Lovable project, open the Supabase integration and authorise Lovable to connect to an existing Supabase project (or create a new one), then Lovable can read and write to it the same way it does with Lovable Cloud.
Last checked 31 Aug 2026
How do I create a database in Lovable?
Ask Lovable to set up Lovable Cloud (or connect your own Supabase project) and describe the tables you need — Lovable provisions the Postgres database and creates the tables from your description.
Last checked 31 Aug 2026
How do I create database tables?
Describe the table's purpose and fields in plain language to Lovable — including which fields are required, their types, and any relationships to other tables — and Lovable generates the table with appropriate row-level security policies.
Last checked 31 Aug 2026
How do I view my database data?
Open the Cloud tab (or ask Lovable) to browse tables, edit rows and run SQL directly inside your project — no separate Supabase login needed.
Last checked 31 Aug 2026
Why isn't Lovable saving data?
Most commonly this is a missing or misconfigured RLS policy blocking the insert/update, an unconnected database, or a form that never calls the backend at all.
Last checked 31 Aug 2026
Why is Supabase returning a 403 error?
A 403 means Row Level Security blocked the request — the current user's role doesn't match any policy allowing that read or write on that table.
Last checked 31 Aug 2026
What is Row Level Security (RLS)?
RLS is a Postgres feature that restricts which rows a query can see or change, enforced per-row on the database itself rather than trusted to your app's code.
Last checked 31 Aug 2026
Do I need RLS on my Lovable app?
Yes, for almost any app with user data, private content or logged-in users — without RLS, anyone can read or write any row via the database's public API.
Last checked 31 Aug 2026
How do I fix RLS errors?
Identify which operation and role is being blocked, then ask Lovable to add or correct the specific policy for that table rather than disabling RLS.
Last checked 31 Aug 2026
Why can users see other users' data?
Almost always a missing or too-permissive RLS policy — either RLS isn't enabled on the table, or a policy allows reading rows regardless of who owns them.
Last checked 31 Aug 2026
How do I safely store API keys?
Store keys as secrets in your backend (Lovable Cloud/Supabase) and call the third-party API from a server/edge function — never put keys in front-end code.
Last checked 31 Aug 2026
How do I use environment variables?
Use `VITE_`-prefixed variables only for non-sensitive, public values baked into the front-end build; use Secrets for anything sensitive that a server/edge function needs.
Last checked 31 Aug 2026
What are Supabase Edge Functions?
Edge Functions are small serverless backend functions that run outside the browser — used for anything requiring a secret key, a third-party call, or logic that shouldn't be trusted to the client.
Last checked 31 Aug 2026
When should I use an Edge Function?
Use one whenever your app needs a secret key, must call a third-party service, or needs logic that shouldn't be trusted to run in the user's browser.
Last checked 31 Aug 2026
How do I upload and store files?
Ask Lovable to add file uploads and it will wire up storage in Lovable Cloud (or your connected Supabase project), including an upload UI and access policies for the files.
Last checked 31 Aug 2026
How do I back up my Lovable database?
Lovable Cloud stores backups you can restore from directly in the Database screen; for extra safety, also ask Lovable to export your data periodically.
Last checked 31 Aug 2026
How do I migrate a database?
Describe the schema change you want in chat and let Lovable write and apply the migration — it handles new tables, columns and RLS policy updates together.
Last checked 31 Aug 2026
Can I move from Lovable Cloud to Supabase?
Yes — Lovable Cloud is a Supabase backend under the hood, and Lovable supports connecting your own Supabase project instead, though moving existing data across takes an export/import step.
Last checked 31 Aug 2026