Navigate to Data + AI Connection area in Astrato (Direct link: https://app.astrato.io/data/sources)
You need to have at minimum Administrator/Creator permissions in Astrato & access to your Supabase tenant.
Create a new connection:
β
This will bring you to the "Connect to Supabase" dialogue. To successfully connect, you need to obtain the Supabase connection URL:
Obtaining the Supabase Connection URL
Connecting via IPV4 direct connection (recommended)
Connecting via the Session Pooler (free projects)
To connect Astrato to Supabase, first, find the Session pooler connection string to Astrato
Transaction pooler connections are IPv4 proxied for free.
Ideal for stateless applications like serverless functions where each interaction with Postgres is brief and isolated.
To find the session pooler string:
Click on πConnect, which appears at the very top left of Supabase Studio's UI.
β
[1] Select Session pooler as the method.
β
β
[2] Take the URL of the full session pooler looks like this:
postgresql://postgres.abcdefghijklmnop:[YOUR-PASSWORD]@aws-1-eu-west-2.pooler.supabase.com:5432/postgres
β
[3] Paste the URL into the Astrato Data Connection Dialogue. By default, SSL mode is set to require, we recommend using this.
β
[4] One successfully connected, select your database
[4] You can then add permission who within your Astrato tenant will have access to read from the database using the credentials, as well as the ability to create Semantic Layers.β
[5] Once successfully connected, you a new Semantic Layer will be created, where you can browse available tables, schemas and query them.
β
Video coming soon
β
π§βπ» Optional: SQL Code to create a new user in Supabase for Astrato Analytics
create user astrato with password '--ENTER YOUR PASSWORD--';
GRANT CONNECT ON DATABASE postgres TO astrato;
-- 3. Grant usage on the 'public' schema (where your tables usually live)
GRANT USAGE ON SCHEMA public TO astrato;
-- 4. Grant access to all EXISTING tables in the public schema
GRANT ALL PRIVILEGES ON ALL TABLES IN SCHEMA public TO astrato;
GRANT ALL PRIVILEGES ON ALL SEQUENCES IN SCHEMA public TO astrato;
-- 5. (Optional) Grant access to all FUTURE tables automatically
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT ALL ON TABLES TO astrato;
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT ALL ON SEQUENCES TO astrato;
alter default privileges in schema public
grant select, insert, update, delete on tables to astrato;
ALTER ROLE astrato LOGIN;
βΉοΈ We recommend not to use the default account to connect to third party tools integrating with Supabase. Consider creating a new db user, for use with Astrato.










