Postgress connection timeout since a week

Describe the problem/error/question

So I’ve been using this workflow for a couple of months but approximately a week ago, the PostgreSQL node stopped working. When I wanted to troubleshoot it, it says this error message that says “connection timeout”.

I use an N8n docker hosted into a Render server and I use a Supabase database with a basic table that saves àmy session IDs and the output and inputs for the AI to remember the conversation. Since it stopped working a week ago, I’ve tried to troubleshoot it for a couple of hours yesterday.

  • I updated my N8n version to 2.8.3; it didn’t work.

  • I updated my database on Supabase; it didn’t work.

  • I also tried to change my port for my PostgreSQL for session pooler 5432 instead of transaction pooler 6543 , but I have the same error.
    Even in the successful workflows, they successfully retried a couple of times but they didn’t get access to the memory. The PostgreSQL doesn’t work so I don’t know what to do with that because every other connection through API, even my super base ones that I connect through OAuth, works. It’s just the PostgreSQL that doesn’t work and I don’t know what to do with that to make my workflow work.

    Also I want to mention that when I delete and recreate my credentials sometimes it loads infinitely and it doesn’t connect. I need to refresh my page and try to re-do the connection to my Postgres credentials. It’s not just an error of workflow; it’s an error with the credential and the connection.

What is the error message (if any)?

What is the error message (if any)?

Please share your workflow


(Select the nodes on your canvas and use the keyboard shortcuts CMD+C/CTRL+C and CMD+V/CTRL+V to copy and paste the workflow.)

Share the output returned by the last node

The connection timed out, consider setting the ‘Retry on Fail’ option in the node settings

Information on your n8n setup

  • n8n version: 2.8.3
  • Database (default: SQLite): Postgress
  • Running n8n via Docker in Render

Hi @Samuel_Ross

1. In Supabase:

  • Use Connect → Transaction pooler → Mode: Session.

  • Copy host, port 5432, DB, user.

  • Reset/copy DB password.

2. In n8n Postgres credentials:

  • Host: aws-0-<region>.pooler.supabase.com

  • Port: 5432

  • DB/User/Password: from Supabase.

  • SSL: enabled.

3. Save the credential, then:

  • Run a simple Postgres node (SELECT 1) to test.

  • If it still times out, update n8n to the latest 2.x that includes the Postgres pool fix.

Okay I’ll try that

the username is usually what breaks it. it cannot just be postgres. it has to be postgres.[your-project-ref]. copy it exactly from the supabase dashboard.

Hi @Samuel_Ross
Welcome to the n8n community :tada:
Supabase automatically pauses free tier databases after 7 days of inactivity. The timing you mentioned (“about a week ago”) matches this exactly. Head over to your Supabase dashboard and check if your database shows a “Paused” status. If it does, just click to restore it and try your connection again. That might be all it takes!

It runs everyday, unfortunately it’s not the issue

Sometimes it works, sometimes it doesn’t but always fails every now and then

Enabling SSL make it never work, disabling it make it work sometimes

Ah got it, that rules that one out!
did you get a chance to try what @A_A4 suggested? If you already tried that and it still didn’t work, a couple other things worth checking:
First, on the Supabase side, do you have any Network Restrictions enabled? If Render’s IP changed recently (which can happen), Supabase might be blocking the connection silently, which would explain the timeout instead of an auth error.
Second, the fact that it loads infinitely when you try to recreate the credentials is a red flag for a network/firewall issue rather than a wrong credential. A wrong password would just fail instantly.

Hope one of those helps narrow it down!

looking at your screenshots I think I spotted two things.

First, the Supabase pooler actually requires SSL to work, but the trick is to enable SSL and also turn on “Ignore SSL Issues (Insecure)” at the same time. Just enabling SSL alone without that option tends to break things in hosted environments like Render.

Second, 15 max connections is probably too much for Supabase’s free plan. Try dropping that to 3 or 5 and see if the intermittent failures get better.

Try both changes together and let us know!

Enforce SSL on incoming connections in Supabase?

leave that off!

Unfortunately I still have the same issue of timming out

I did that instead. Work fine and it’s faster

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.