Quickbooks ERR_CONNECTION_REFUSED

Hi all, I’ve followed the guide to connect n8n to QuickBooks but when I click on “connect account” I get ERR_CONNECTION_REFUSED.

My workflow is: “Create New Credential” → copy the OAuth Redirect URL into a new URI in Quickbooks and save it → copy both keys into n8n and set the environment to Sandbox → click on connect my account.

I am running a self-hosted installation on VPS server, in a docker container, no firewall rules are applied at this stage.

What am I doing wrong?

n8n version: 1.31.2
database: postgresdb
Running n8n via Cosmos OS in a dockerised container
OS: Ubuntu 22.04

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

Are there any more specific errors or codes? Did you set up OAuth credentials with any other service yet or this is the first one?

Is the URI in the OAuth credential screen the correct url you use to access n8n and is it prefixed by https:// ?

Let me know

Hi Liam, that is the only error that shows up on the small browser window that opens when clicking to connect the account.

I did copy/paste of that URL.


In order to really make n8n useful you need to connect it to a domain instead of localhost.

localhost is a way of saying “here on this machine/this machine’s ip address”, if you substituted the localhost with the computers local IP you would still be able to access it. You would actually be able to access it that way anywhere on the same network.

But outside of your local network, nothing can get to your n8n instance and localhost operates over http and almost every OAuth2 requires https.

A very easy and free way to do this is with cloudflare tunnels.

You will also need to change some n8n env variables like N8N_EDITOR_BASE_URL and WEBHOOK_URL to match your full domain with https:// to ensure everything works as expected

1 Like

n8n is already installed on a domain with a reverse proxy and ssl.
I probably have to change its environment variable.
I give it a try and revert back.


I added the env variables and changed the URI → account connected.

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