# Connect website with node red

**URL:** <https://discourse.nodered.org/t/connect-website-with-node-red/26080>\
**Category:** General\
**Created:** [4 May 2020 18:29 UTC](https://discourse.nodered.org/t/connect-website-with-node-red/26080 "2020-05-04T18:29:32Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Beefy\_carrot](https://avatars.discourse-cdn.com/v4/letter/b/ccd318/32.png) [@Beefy\_carrot](https://discourse.nodered.org/u/Beefy_carrot)\
**Post date:** [4 May 2020 18:29 UTC](https://discourse.nodered.org/t/connect-website-with-node-red/26080/1 "2020-05-04T18:29:32Z")

</div>

How can i connect node red with a website. note: the website and node red will run independent.

I want to use commands from the website to change rules for data output.

---

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [4 May 2020 18:33 UTC](https://discourse.nodered.org/t/connect-website-with-node-red/26080/2 "2020-05-04T18:33:52Z")

</div>

You can create endpoints (http in & out nodes) in node red that you can call from the website.

You can use http request nodes to request (POST / GET) to call from node-red to your website's server.

Search the flow library for examples.

---

<div class="post-metadata">

**Author:** ![Beefy\_carrot](https://avatars.discourse-cdn.com/v4/letter/b/ccd318/32.png) [@Beefy\_carrot](https://discourse.nodered.org/u/Beefy_carrot)\
**Post date:** [4 May 2020 18:35 UTC](https://discourse.nodered.org/t/connect-website-with-node-red/26080/3 "2020-05-04T18:35:09Z")

</div>

Thanks mate 🙂

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [5 May 2020 00:54 UTC](https://discourse.nodered.org/t/connect-website-with-node-red/26080/4 "2020-05-05T00:54:17Z")

</div>

You can also use uibuilder as the front-end can be run from a separate web server if you want and you can link to the Node-RED server over websockets.

---

<div class="post-metadata">

**Author:** ![Beefy\_carrot](https://avatars.discourse-cdn.com/v4/letter/b/ccd318/32.png) [@Beefy\_carrot](https://discourse.nodered.org/u/Beefy_carrot)\
**Post date:** [5 May 2020 02:39 UTC](https://discourse.nodered.org/t/connect-website-with-node-red/26080/5 "2020-05-05T02:39:17Z")

</div>

didnt get the cli to work, didnt find much material on it so gave uibuilder up.

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [5 May 2020 08:03 UTC](https://discourse.nodered.org/t/connect-website-with-node-red/26080/6 "2020-05-05T08:03:03Z")

</div>

There isn't much documentation on using the front-end from another server because nobody has _asked_ for it. 😉

---

<div class="post-metadata">

**Author:** ![Beefy\_carrot](https://avatars.discourse-cdn.com/v4/letter/b/ccd318/32.png) [@Beefy\_carrot](https://discourse.nodered.org/u/Beefy_carrot)\
**Post date:** [5 May 2020 10:50 UTC](https://discourse.nodered.org/t/connect-website-with-node-red/26080/7 "2020-05-05T10:50:22Z")

</div>

no i get that xD but on how to use cli with uibuilder. atleast i didnt undertstand how to do it

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [5 May 2020 14:09 UTC](https://discourse.nodered.org/t/connect-website-with-node-red/26080/8 "2020-05-05T14:09:53Z")

</div>

Do you mean the VueJS CLI?

If so and if you are using your own web server (rather than Node-RED) to deliver the front-end, then all you need to do is ensure that you include the appropriate libraries including the uibuilderfe.js library which you could obtain from the Node-RED server or you could copy it to your own server. When you build your VueJS app code using webpack, the uibuilderfe library will be included with everything else.

Really, the only differences when using your own web server are:

- You need to correct any URL's if using the default template code

- You need to manually specify the [Socket.IO](http://Socket.IO) channel and URL of the [Socket.IO](http://Socket.IO) client when starting up the uibuilder front-end:

- You can't edit your front-end code in Node-RED's Editor of course

- You will want to choose whether you want Node-RED to serve the front-end code for other libraries (Vue, bootstrap, etc) or whether you want to serve that code from your own web server (which may be slightly more secure).

I'm always happy to go through any details.

---

<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:** [4 July 2020 14:11 UTC](https://discourse.nodered.org/t/connect-website-with-node-red/26080/9 "2020-07-04T14:11:55Z")

</div>

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