How to connect Supabase to Railway
yoshimendokusee
FREEOP

3 months ago

There's no option of supabase variable in my project, only postgres

34 Replies

Are you hosting Supabase or are you connecting an external instance?


yoshimendokusee
FREEOP

3 months ago

connecting external instance


yoshimendokusee
FREEOP

3 months ago

i already have a project in supabase but it is still empty


yoshimendokusee
FREEOP

3 months ago

is this correct

image.png

Attachments


You need to redeploy your service to use the variables.


yoshimendokusee
FREEOP

3 months ago

but where do i get the Database_URL tho


yoshimendokusee
FREEOP

3 months ago

it saids pooler something


Go to your project dashboard and hover over the URL.


yoshimendokusee
FREEOP

3 months ago

this?

image.png

Attachments


94864.png

Attachments


yoshimendokusee
FREEOP

3 months ago

so it is the same with Supabase_url variable?


I don't know what you put.

If it's the same, then it's the same.

The URL should start with postgresql://.


It should be called "Direct connection string" in Supabase dashboard.


yoshimendokusee
FREEOP

3 months ago

The string you shared is a Direct Connection URL. While it looks correct, it will likely cause your app on Railway to crash with a Network is unreachable or ENETUNREACH error.


yoshimendokusee
FREEOP

3 months ago

it says this


What said that...


yoshimendokusee
FREEOP

3 months ago

it says that railway only support Ipv4 connection but supabase uses IPv6


yoshimendokusee
FREEOP

3 months ago

is it true tho


yoshimendokusee
FREEOP

3 months ago

does railway now supports Ipv6? since i researched again and it said yes


(no markdown available for this content)


3 months ago

That costs extra money, can't you just enable outbound IPv6 on the railway service?


3 months ago

outbound ipv6 is a feature flag option



3 months ago

1772986476_0CGHiUSiRI.png

Attachments


yoshimendokusee
FREEOP

3 months ago

so i dont need to change the port 5432 to 6543


yoshimendokusee
FREEOP

3 months ago

or change the pooler in supabase


Oh cool. Didn’t know it’s now a feature flag.


yoshimendokusee
FREEOP

3 months ago

owh damn


yoshimendokusee
FREEOP

3 months ago

image.png

Attachments


yoshimendokusee
FREEOP

3 months ago

damn tysm!


yoshimendokusee
FREEOP

3 months ago

lastly do i need to remove the syntax ${{}} in railway


If they are reference variables, no. You need to keep them.


yoshimendokusee
FREEOP

3 months ago

how about for Supabase_URL?


I don't know how you structured your project. If it's a reference variable, then you need the ${{}} syntax.


Welcome!

Sign in to your Railway account to join the conversation.

Loading...