Postgres mcp: can it connect to remote postgres db?

Hi all,

I am trying to use mcp postgres of this in Cursor (Version: 0.47.8), i have set username and pwd in the mcp.json, but Cursor said “fail to create client”.

Here is my config

Is it becasue the server i configed isn’t on localhost? I didn’t see any document mention it only can connect to localhost postgres db server.

Or i must run docker? seems not, as npx way is also ok, right?

pls help, thanks in advance!

Hi, as this is dependent mostly on the MCP server you use best would be checking with Anthropic which seems to have made that server or checking in their forum.

From my experience you can access remote clients but the config details or capability depends really on the MCP server itself.

They likely have on their github already had that question.

1 Like