# Cannot connect to Node red instance outside local network

**URL:** <https://discourse.nodered.org/t/cannot-connect-to-node-red-instance-outside-local-network/70329>\
**Category:** General\
**Tags:** http-request, security\
**Created:** [9 November 2022 14:11 UTC](https://discourse.nodered.org/t/cannot-connect-to-node-red-instance-outside-local-network/70329 "2022-11-09T14:11:42Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Igdesgn](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Igdesgn](https://discourse.nodered.org/u/Igdesgn)\
**Post date:** [9 November 2022 14:11 UTC](https://discourse.nodered.org/t/cannot-connect-to-node-red-instance-outside-local-network/70329/1 "2022-11-09T14:11:42Z")

</div>

I have Node Red running on a Raspberry Pi 3B+. I have set up https certification with acme.sh, zerossl and duckdns. Everything is OK in the settings file, and when starting it says in log file that it is listening on 127.0.0.1:1880. I have port forwarded the ports 22 and 1880 to my pi, with a static dchp ip, in my router, and I can connect to the node red instance using the dedicated dns within my local network, but once I go anywhere else, I cannot connect to [mydns.com:1880](http://mydns.com:1880). But I can open an ssh connection to [mydns.com:22](http://mydns.com:22), is there anything I am doing wrong with node-red?

So I can connect to my pi externally using port 22, but not 1880, why? Is it something I have missed in node red?

Appreciate all answers!

---

<div class="post-metadata">

**Author:** ![Igdesgn](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Igdesgn](https://discourse.nodered.org/u/Igdesgn)\
**Post date:** [9 November 2022 18:53 UTC](https://discourse.nodered.org/t/cannot-connect-to-node-red-instance-outside-local-network/70329/2 "2022-11-09T18:53:55Z")

</div>

I believe there is something wrong with node-red settings, or something that points to the dns address/node-red instance. If I remove the https config in settings, I can once again log in externally. But it does not work with https, although the certificate works, and is correct. I do not get any error in the logs either. Tried to set up a secondary dns to node red instance, and made it work, but got a message that the https certificate belongs to my first dns address…

---

<div class="post-metadata">

**Author:** ![Igdesgn](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Igdesgn](https://discourse.nodered.org/u/Igdesgn)\
**Post date:** [9 November 2022 18:59 UTC](https://discourse.nodered.org/t/cannot-connect-to-node-red-instance-outside-local-network/70329/3 "2022-11-09T18:59:53Z")

</div>

Another discovery: I can connect on the original dns, only if I remove requirehttps from the settings. Which means I will not be able to connect with https…

---

<div class="post-metadata">

**Author:** ![Igdesgn](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Igdesgn](https://discourse.nodered.org/u/Igdesgn)\
**Post date:** [9 November 2022 19:48 UTC](https://discourse.nodered.org/t/cannot-connect-to-node-red-instance-outside-local-network/70329/4 "2022-11-09T19:48:08Z")

</div>

Talking to yourself really makes you think. Figured it out. Had to set requireHttps to false, and then connect using https//:mydns.com:1880. That is the only way it works, cannot connect using only http connection.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [23 November 2022 19:48 UTC](https://discourse.nodered.org/t/cannot-connect-to-node-red-instance-outside-local-network/70329/5 "2022-11-23T19:48:38Z")

</div>

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