Customer.io Supabase "cannot assign requested address" fix
The "cannot assign requested address" error means Customer.io tried Supabase's IPv6-only direct host and could not connect. Use the pooler hostname, or buy Supabase's IPv4 add-on. "Tenant or user not found" usually means the pooler username lacks the project ref suffix, or the region host is wrong.
Sohail Hussain8 min readShort answer
- The cannot assign requested address error means the connection was attempted to Supabase's IPv6-only direct host and failed from the client side. Try the pooler host from your Supabase dashboard as a workaround, or enable Supabase's paid IPv4 add-on, and confirm the current behavior in Supabase's connection documentation.
- Tenant or user not found means the pooler could not route your login to a project. Use the username format role.your-project-ref and the pooler host for your project's region.
You set up a Postgres source in Customer.io, pointed it at Supabase, and the connection test came back with one of these:
dial tcp [IPv6 address]:5432: connect: cannot assign requested address: query failed
XX000 - Tenant or user not found: query failed
The first usually appears when you paste the direct database host. The second usually appears after you switch to the pooler and something in the host or username is off. The pooler route costs nothing to try, but it is a workaround whose results depend on your project, so verify each step.
Why it happens
The IPv6 error
cannot assign requested address is the operating system's EADDRNOTAVAIL. It comes from the connecting side (here, Customer.io's infrastructure), not from Supabase rejecting you. The client was handed an IPv6 destination and had no usable IPv6 route or source address.
Supabase's direct connection host (db.{project-ref}.supabase.co) resolves to IPv6 only unless the project has the IPv4 add-on, so a client without working IPv6 fails on it. People who hit this combination report that Customer.io's database connection could not use IPv6. I have not seen Customer.io document that, so treat it as a likely explanation, not a confirmed fact. Customer.io's Postgres source documentation is the place to check what network requirements it lists.
The tenant error
XX000 is PostgreSQL's generic internal-error class. Tenant or user not found comes from Supabase's pooler (Supavisor). It is not a bad-password error. It is a routing error: the pooler reads the username to work out which project you mean, and it found none.
Common triggers, most likely first:
- The username is plain
postgresinstead ofpostgres.{project-ref}. - The host is a pooler host for the wrong region.
- The project ref in the username has a typo or belongs to a different project.
The original poster reported that the transaction pooler returned this error for them, so expect to adjust host and username format.
Fix 1: try the pooler host with the right username
This costs nothing. Whether it solves the IPv6 problem depends on your project and on what Supabase currently documents for pooler addressing, so read Supabase's database connection guide alongside these steps.
- In the Supabase dashboard, open your project and click Connect.
- Choose the pooler connection strings (session mode or transaction mode).
- Copy the host exactly as shown. It looks like
aws-0-us-east-1.pooler.supabase.com, with your project's region in it. - Set the username to
postgres.{project-ref}. The ref is the string in your project URL. - Enter your database password and the database name
postgres. - Re-run the connection test in Customer.io.
Host: aws-0-us-east-1.pooler.supabase.com
Port: 5432 (session mode) or 6543 (transaction mode)
Database: postgres
User: postgres.abcdefghijklmnop
Password: your database password
Session mode behaves like a normal Postgres connection. Transaction mode does not support prepared statements, which some clients use by default. If a sync tool fails in odd ways on 6543, try session mode first. Pooler details change over time, so trust the strings the dashboard shows today over the example above.
Check the host field
Pasting the direct host (the one starting with db.) with port 5432 is what triggers the IPv6 error. Confirm the host field really contains the pooler address.
If you still get the IPv6 error with a pooler host, or the tenant error will not go away, the pooler is not working for your setup and Fix 3 is the next step.
Fix 2: test a limited-access user (unverified)
The original poster concluded that the IPv4 add-on was the only fix and that, after buying it, they lost the option of a limited-access database user. They did not explain why. I have not confirmed whether a custom role can connect through the pooler, so treat this as a test, not a promise. Supabase's pooler username format is role.project-ref, which suggests a custom role would be addressed as cio_reader.{project-ref}; your own psql test below is what settles it.
Create the role in the Supabase SQL editor and grant only what the sync needs:
create role cio_reader with login password 'use-a-long-random-password';
grant usage on schema public to cio_reader;
grant select on public.your_table to cio_reader;
Then test cio_reader.{project-ref} with psql (see the test section). Use it in Customer.io only if that works. Two traps:
- If the table has row level security enabled, a role without bypass rights sees only the rows its policies allow, which can be zero. The query succeeds and the sync looks empty.
- Grants do not cover tables created later. Run
grant selectagain for new tables.
Fix 3: enable the IPv4 add-on
If the pooler does not work for you, turn on Supabase's IPv4 add-on from your project's settings (look for add-ons in the project settings). It is paid; check the current price in your own dashboard, since I am not quoting one. Once active, the direct host gets an IPv4 address and the original connection string should work.
This is the route the original poster took. The trade-off they reported was losing the limited-access user option; if you need a restricted role, test one against the direct host before committing to the add-on's monthly cost.
Test before you save the sync
Test outside Customer.io first, from a machine you control. That separates credential problems from Customer.io problems.
psql "postgresql://cio_reader.{project-ref}:{password}@aws-0-us-east-1.pooler.supabase.com:5432/postgres" -c "select 1;"
If that works, start Customer.io with a deliberately simple query: one table, a few columns, and a filter on a timestamp column such as last_sync_time. The poster validated the connection with a simple SELECT of that shape.
select id, email, updated_at
from public.your_table
where last_sync_time > now() - interval '1 day';
Add joins and extra columns only after the plain version passes. On a large table, index the timestamp column so each sync does not scan everything.
Which cause do you have
| What you see | Cause | Fix |
|---|---|---|
dial tcp [...]:5432 ... cannot assign requested address | Direct host is IPv6 only | Pooler host, or IPv4 add-on |
Tenant or user not found | Username lacks .project-ref, or wrong region host | Re-copy host and username from Connect |
password authentication failed | Wrong or reset password | Reset the database password in Supabase |
| Connects, but zero rows | Row level security or missing grants | Add a policy or a grant |
Checklist before you try again
- Host is the pooler host for your project's region, not the
db.direct host. - Username is
role.project-ref, with the correct ref. - Port matches the mode you copied (5432 session, 6543 transaction).
- Password is current and has no stray spaces.
- The role has
usageon the schema andselecton the table. psqlfrom your own machine succeeds with the same values.
If nothing works
If the pooler string works from psql but fails from Customer.io, contact Customer.io support. If psql fails too, contact Supabase support. Include the exact error text, the time of the attempt with timezone, the host and port you entered, your project ref, and what you already tried. Never send the password.
Subject: Postgres source fails to connect to Supabase
Hi, my Postgres source in Customer.io fails its connection test.
Error: "XX000 - Tenant or user not found: query failed"
Time of attempt: {date, time, timezone}
Host and port: aws-0-us-east-1.pooler.supabase.com:5432
Username format: {role}.{project-ref}
The same string works from psql on my machine: {yes/no}
Already tried: pooler host, session and transaction mode, re-copied the string from the Supabase Connect page.
Can you confirm whether IPv6-only destinations are supported, or check why the login is rejected?
If you restrict database access by network, add any source IPs Customer.io documents for its connections. Network restrictions usually cause timeouts rather than the two errors here, so that is a separate problem.
Common questions
Does the IPv4 add-on fix the tenant error too?
No. The tenant error is a pooler routing problem tied to the username and host. The add-on changes how the direct host resolves, so it addresses the IPv6 error only.
Is a wrong password the cause of "Tenant or user not found"?
Not usually. A wrong password gives a password authentication error. The tenant error means the pooler could not map your username or host to a project.
Can I avoid giving Customer.io full database access?
Maybe. A dedicated role with select on one table is the right goal, but I have not confirmed it works through the pooler, and the original poster reported losing this option after buying the add-on. Test the role with psql against whichever host you end up using before relying on it.
Explore: Email Marketing Strategy
Related Articles
414 Request-URI Too Large in n8n's Amazon SES node: fix
The error 414 Request-URI Too Large in n8n's AWS SES node means a server in the path refused a request whose URL was too long, which a long HTML body can cause when it travels in the URL. Send through the SES v2 API with an HTTP Request node, or use SES SMTP.
Access denied, bad outbound sender: Outlook cold email fix
"Access denied, bad outbound sender" (550 5.1.8) means Microsoft 365 has put your mailbox on its restricted users list for spam-like sending. An admin must unblock it under Restricted entities in the Microsoft Defender portal. Then clean your list, lower your volume and resume gradually.
Acoustic Campaign "Application error" on login: bookmark fix
Acoustic Campaign shows "application error" at login when you open it from a bookmark saved while you were logged in, because the bookmark carries the old session. Log out, type your pod URL (campaign-us-[X].goacoustic.com) into the address bar, log in, then save a fresh bookmark.
ActiveCampaign 502 Bad Gateway and Tags Failed to Load: Fixes
"Bad gateway Error code 502" in ActiveCampaign means Cloudflare, the proxy in front of the app, got no valid response from ActiveCampaign's servers. That is usually their side. Check the status page, retry in a clean browser session, clear cookies, then send support the Ray ID if it persists.
Ready to supercharge your email marketing?
Start sending smarter emails with AI-powered campaigns. No credit card required.
Get Started Free