© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
SupabaseS
Supabase•2mo ago•
5 replies
st843

Unable to connect to read replica even using pooler

Hi Supabase Support Team,

I’m running into an issue accessing a read replica from an IPv4-only environment, and after extensive debugging this is what i've noticed:

Context:
- environment is IPv4-only
- direct database and replica hostnames of the form: db.<project>-rr-<region>.supabase.co
are IPv6-only, so they are not reachable from my environment. I can successfully connect to the primary database via the Supabase pooler: aws-0-<primary-region>.pooler.supabase.com using the postgres user over IPv4

What i've tried:
- Connecting to the pooler with: target_session_attrs=read-only This consistently fails with: session is not read-only

even though a read replica exists and is healthy.

Using the documented / community-recommended approach of connecting via the pooler as:

supabase_read_only_user.<project_ref>

However, this role does not exist in our project:

ERROR: role "supabase_read_only_user.<project_ref>" does not exist

Attempting to create our own read-only role:
- The role can be created successfully in Postgres

But authentication through the Supabase pooler fails with:
- FATAL: Tenant or user not found

This suggests the pooler only allows specific managed users.

Conclusion:
- Direct replica access is IPv6-only
- IPv4 access requires the pooler
- Pooler-based replica access requires the built-in supabase_read_only_user - could you confirm this?


Thanks in advance.
Supabase banner
SupabaseJoin
Supabase gives you the tools, documentation, and community that makes managing databases, authentication, and backend infrastructure a lot less overwhelming.
45,816Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Read replica connection pool
SupabaseSSupabase / help-and-questions
5mo ago
Failed to connect Session Pooler: MaxClientsInSessionMode
SupabaseSSupabase / help-and-questions
4mo ago
Read Replica Adoption at company using current Postgres
SupabaseSSupabase / help-and-questions
4y ago
Read-replica promotion + PostgREST version
SupabaseSSupabase / help-and-questions
6mo ago