[{"data":1,"prerenderedAt":290},["ShallowReactive",2],{"blog-\u002Fblog\u002F2023\u002F01\u002Fgetting-started-with-node-red":3},{"id":4,"title":5,"body":6,"description":12,"extension":279,"meta":280,"navigation":285,"path":286,"seo":287,"stem":288,"__hash__":289},"blog\u002Fblog\u002F2023\u002F01\u002Fgetting-started-with-node-red.md","Getting Started with Node-RED",{"type":7,"value":8,"toc":268},"minimark",[9,13,16,21,24,29,40,43,46,49,78,81,90,105,109,124,144,152,165,174,181,189,196,204,208,221,225,228,232,235,239,242,247,251,264],[10,11,12],"p",{},"Node-RED is a visual programming tool for working with IoT devices and web services. It allows users to create flows using a drag-and-drop interface, making it easy to connect different nodes together to build powerful automations.",[10,14,15],{},"In this blog post, we'll take a look at how to get started with Node-RED and create some basic flows. We'll also explore the palette manager, a powerful feature that allows users to install and manage additional nodes for Node-RED.",[17,18,20],"h3",{"id":19},"installing-node-red","Installing Node-RED",[10,22,23],{},"First, you'll need to get an installation of Node-RED up and running. There are several ways to do this. We suggest using FlowFuse as it's very easy to get Node-RED running. You can also install Node-RED locally using npm (Node Package Manager), which comes with Node.js.",[25,26,28],"h4",{"id":27},"flowfuse","FlowFuse",[10,30,31,32,39],{},"To get Node-RED running on FlowFuse ",[33,34,38],"a",{"href":35,"rel":36},"https:\u002F\u002Fapp.flowfuse.com\u002Faccount\u002Fcreate",[37],"nofollow","sign up as a new user",". New users are enrolled in a trial and a Node-RED instance will be started for you within a minute.",[10,41,42],{},"Once that instance has booted up you can access Node-RED by pressing \"Open Editor\".",[25,44,45],{"id":45},"npm",[10,47,48],{},"To install Node-RED locally using npm, open up your terminal and type the following command:",[50,51,56],"pre",{"className":52,"code":53,"language":54,"meta":55,"style":55},"language-bash shiki shiki-themes github-light github-dark","npm install -g node-red\n","bash","",[57,58,59],"code",{"__ignoreMap":55},[60,61,64,67,71,75],"span",{"class":62,"line":63},"line",1,[60,65,45],{"class":66},"sScJk",[60,68,70],{"class":69},"sZZnC"," install",[60,72,74],{"class":73},"sj4cs"," -g",[60,76,77],{"class":69}," node-red\n",[10,79,80],{},"Once Node-RED is installed, you can start it by running the following command:",[50,82,84],{"className":52,"code":83,"language":54,"meta":55,"style":55},"node-red\n",[57,85,86],{"__ignoreMap":55},[60,87,88],{"class":62,"line":63},[60,89,83],{"class":66},[10,91,92,93,98,99,104],{},"This will start the Node-RED server and open up the ",[33,94,97],{"href":95,"rel":96},"http:\u002F\u002Flocalhost:1880",[37],"editor in your web browser",". You can also specify a different port or a settings file if you want to. If you want to run Node-RED locally but manage it remotely through FlowFuse, check out ",[33,100,103],{"href":101,"rel":102},"https:\u002F\u002Fflowfuse.com\u002Fblog\u002F2025\u002F09\u002Finstalling-node-red\u002F",[37],"this guide",".",[17,106,108],{"id":107},"first-flow","First Flow",[10,110,111,112,115,116,119,120,123],{},"Now that you have Node-RED running, let's take a look at how to create a simple flow. In this example, we'll create a simple \"Hello World\" endpoint. To do this, we'll use the ",[57,113,114],{},"http in",", ",[57,117,118],{},"http response",", and the ",[57,121,122],{},"change"," nodes, which can be found in the common nodes menu on the left of Node-RED.",[10,125,126,127,129,130,132,133,135,136,138,139,135,141,143],{},"First, drag an ",[57,128,114],{}," node into the editor. This node will listen for incoming HTTP requests. Next drag in the \"change\" and the ",[57,131,118],{}," node into the editor. Connect the ",[57,134,114],{}," node to the ",[57,137,122],{}," node and connect the ",[57,140,122],{},[57,142,118],{}," node. Your flow should look similar to this:",[10,145,146],{},[147,148],"img",{"alt":149,"src":150,"title":151},"\"Screenshot showing the HTTP-in, Change, and HTTP-response nodes that we will be using throughout this blog for demonstration.\"","\u002Fblog\u002F2023\u002F01\u002Fimages\u002Fthree-nodes.png","Screenshot showing the HTTP-in, Change, and HTTP-response nodes that we will be using throughout this blog for demonstration.",[10,153,154,155,157,158,161,162,104],{},"To configure the ",[57,156,114],{}," node, double-click on it to open its properties. Here, you can set the URL that the node will listen to, as well as the method (GET, POST, etc.). In this example, we'll set the URL to ",[57,159,160],{},"\u002Fhello"," and the method to ",[57,163,164],{},"GET",[10,166,167,168,170,171,173],{},"Now we need to set what the endpoint will respond with, we will do that in the ",[57,169,122],{}," node. Double-click the ",[57,172,122],{}," node then add \"Hello World\" to the field which says \"to the value\". It should look like this:",[10,175,176],{},[147,177],{"alt":178,"src":179,"title":180},"\"Configuring the change node to set the payload to Hello World\"","\u002Fblog\u002F2023\u002F01\u002Fimages\u002Fset-reply.png","Configuring the change node to set the payload to Hello World",[10,182,154,183,185,186,188],{},[57,184,118],{}," node, double-click on it to open its properties. Here, you should set the \"Status Code\" to be 200. This is not vital for the demo to work but it's good practice to return the correct codes when something connects to an API. Status code 200 means the API responded OK. This is how your ",[57,187,118],{}," node should look:",[10,190,191],{},[147,192],{"alt":193,"src":194,"title":195},"\"Configuring the status node to set the response to 200\"","\u002Fblog\u002F2023\u002F01\u002Fimages\u002Fresponse-code.png","Configuring the status node to set the response to 200",[10,197,198,199,104],{},"You can read more about HTTP response codes in ",[33,200,203],{"href":201,"rel":202},"https:\u002F\u002Fen.wikipedia.org\u002Fwiki\u002FList_of_HTTP_status_codes",[37],"this article",[17,205,207],{"id":206},"testing-your-flow","Testing Your Flow",[10,209,210,211,215,216,220],{},"Now that we have our flow set up, we can deploy it by clicking the \"Deploy\" button in the top right corner of the editor. Once the flow is deployed, you can test it by opening up a web browser. If you installed Node-RED using npm navigate to \"",[33,212,213],{"href":213,"rel":214},"http:\u002F\u002Flocalhost:1880\u002Fhello",[37],"\". If you are working on FlowFuse and running cloud hosted instance, use your instance URL with \"\u002Fhello\" added to the end, it should look something like \"",[33,217,218],{"href":218,"rel":219},"https:\u002F\u002Fyour-instance-name.flowfuse.cloud\u002Fhello",[37],"\". You should see \"Hello World!\" displayed in the browser.",[17,222,224],{"id":223},"debug-output","Debug Output",[10,226,227],{},"One of the most powerful features in Node-RED is the ability to debug your flow. This can be done by adding a debug node to your flow and connecting it to the nodes you want to debug. When a message is sent through the connected node, the debug node will print the message in the debug sidebar on the right side of the editor. This can be very helpful when trying to understand how a flow is working or troubleshoot any issues.",[17,229,231],{"id":230},"the-palette-manager","The Palette Manager",[10,233,234],{},"In addition to the built-in nodes, Node-RED also has a palette manager feature which allows users to easily install and manage additional nodes from the community. To access the palette manager, go to the menu in the top right corner and select \"Manage Palette\". Here, you can search for and install new nodes, as well as update or remove existing ones. This is a great way to extend the functionality of Node-RED and add new capabilities to your flows.",[17,236,238],{"id":237},"import-the-flow","Import the flow",[10,240,241],{},"If you want to view this flow you can import it using the code below. Copy the code then select Import from the top right menu in Node-RED. Paste the code into the field then press Import.",[243,244],"render-flow",{":height":245,"flow":246},"200","WwogICAgewogICAgICAgICJpZCI6ICJhNzQyZTdhOTU2OTdiYjQwIiwKICAgICAgICAidHlwZSI6ICJodHRwIGluIiwKICAgICAgICAieiI6ICI5ZTlhZjNjYWE0ZGMxNGQzIiwKICAgICAgICAibmFtZSI6ICIiLAogICAgICAgICJ1cmwiOiAiL2hlbGxvIiwKICAgICAgICAibWV0aG9kIjogImdldCIsCiAgICAgICAgInVwbG9hZCI6IGZhbHNlLAogICAgICAgICJzd2FnZ2VyRG9jIjogIiIsCiAgICAgICAgIngiOiAxODAsCiAgICAgICAgInkiOiAyMDAsCiAgICAgICAgIndpcmVzIjogWwogICAgICAgICAgICBbCiAgICAgICAgICAgICAgICAiODgzZTdkNTk3ZjdjN2M0YiIKICAgICAgICAgICAgXQogICAgICAgIF0KICAgIH0sCiAgICB7CiAgICAgICAgImlkIjogImFjYTAyNGRjYjc5YmRiOTIiLAogICAgICAgICJ0eXBlIjogImh0dHAgcmVzcG9uc2UiLAogICAgICAgICJ6IjogIjllOWFmM2NhYTRkYzE0ZDMiLAogICAgICAgICJuYW1lIjogIiIsCiAgICAgICAgInN0YXR1c0NvZGUiOiAiMjAwIiwKICAgICAgICAiaGVhZGVycyI6IHt9LAogICAgICAgICJ4IjogNTAwLAogICAgICAgICJ5IjogMjAwLAogICAgICAgICJ3aXJlcyI6IFtdCiAgICB9LAogICAgewogICAgICAgICJpZCI6ICI4ODNlN2Q1OTdmN2M3YzRiIiwKICAgICAgICAidHlwZSI6ICJjaGFuZ2UiLAogICAgICAgICJ6IjogIjllOWFmM2NhYTRkYzE0ZDMiLAogICAgICAgICJuYW1lIjogIiIsCiAgICAgICAgInJ1bGVzIjogWwogICAgICAgICAgICB7CiAgICAgICAgICAgICAgICAidCI6ICJzZXQiLAogICAgICAgICAgICAgICAgInAiOiAicGF5bG9hZCIsCiAgICAgICAgICAgICAgICAicHQiOiAibXNnIiwKICAgICAgICAgICAgICAgICJ0byI6ICJIZWxsbyBXb3JsZCIsCiAgICAgICAgICAgICAgICAidG90IjogInN0ciIKICAgICAgICAgICAgfQogICAgICAgIF0sCiAgICAgICAgImFjdGlvbiI6ICIiLAogICAgICAgICJwcm9wZXJ0eSI6ICIiLAogICAgICAgICJmcm9tIjogIiIsCiAgICAgICAgInRvIjogIiIsCiAgICAgICAgInJlZyI6IGZhbHNlLAogICAgICAgICJ4IjogMzQwLAogICAgICAgICJ5IjogMjAwLAogICAgICAgICJ3aXJlcyI6IFsKICAgICAgICAgICAgWwogICAgICAgICAgICAgICAgImFjYTAyNGRjYjc5YmRiOTIiCiAgICAgICAgICAgIF0KICAgICAgICBdCiAgICB9Cl0=",[17,248,250],{"id":249},"whats-next","What's Next?",[10,252,253,254,258,259,104],{},"Well done, you've now got your first flow up and running. Enjoy using Node-RED and thanks for reading. Now if you want to start with your first beginner friendly project, building a weather dashboard is great, read this ",[33,255,257],{"href":256},"\u002Fblog\u002F2025\u002F12\u002Fgetting-weather-data-in-node-red\u002F","article for getting started",". If you'd like to dive deeper into more Node-RED capabilities and how it can help in an enterprise setting, check out our ",[33,260,263],{"href":261,"rel":262},"https:\u002F\u002Fflowfuse.com\u002Febooks\u002Fbeginner-guide-to-a-professional-nodered\u002F",[37],"eBook The Ultimate Beginner Guide to a Professional Node-RED",[265,266,267],"style",{},"html pre.shiki code .sScJk, html code.shiki .sScJk{--shiki-default:#6F42C1;--shiki-dark:#B392F0}html pre.shiki code .sZZnC, html code.shiki .sZZnC{--shiki-default:#032F62;--shiki-dark:#9ECBFF}html pre.shiki code .sj4cs, html code.shiki .sj4cs{--shiki-default:#005CC5;--shiki-dark:#79B8FF}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":55,"searchDepth":269,"depth":269,"links":270},2,[271,273,274,275,276,277,278],{"id":19,"depth":272,"text":20},3,{"id":107,"depth":272,"text":108},{"id":206,"depth":272,"text":207},{"id":223,"depth":272,"text":224},{"id":230,"depth":272,"text":231},{"id":237,"depth":272,"text":238},{"id":249,"depth":272,"text":250},"md",{"navTitle":5,"excerpt":281},{"type":7,"value":282},[283],[10,284,12],{},true,"\u002Fblog\u002F2023\u002F01\u002Fgetting-started-with-node-red",{"title":5,"description":12},"blog\u002F2023\u002F01\u002Fgetting-started-with-node-red","qCEztP7sw1TqeibW6ESjHitb6nJHYSFOtpf3zZSEhxc",1780070550192]