Zbotic Logo Zbotic Logo
  • Home
  • Shop
  • Sale
  • 3D Print Service
  • PCB Service
  • B2B
  • Blogs
  • Contact Us
0 0

View Wishlist Add all to cart

0 0
0 Shopping Cart
Shopping cart (0)
Subtotal: ₹0.00

View cartCheckout

  • Shop
  • About Us
  • Contact Us
  • Reseller
  • Blogs
020 69134444
1800 209 0998
[email protected]
Help Desk
Facebook Twitter Instagram Linkedin YouTube
Zbotic Logo Zbotic Logo
0 0

View Wishlist Add all to cart

0 0
0 Shopping Cart
Shopping cart (0)
Subtotal: ₹0.00

View cartCheckout

All departments
  • 3D Print Service
  • 3D Printer
  • Batteries & Chargers
  • Development Boards
  • Drone Parts
  • EBike parts
  • Sensor Modules
  • Electronic Components
  • Electronic Modules
  • IoT and Wireless
  • Mechanical Parts and Workbench Tools
  • Motors & Drivers & Pumps & Actuators
  • DIY and Robot Kits
  • Show more
  • Home
  • Shop
  • Sale
  • 3D Print Service
  • PCB Service
  • B2B
  • Blogs
  • Contact Us
Return to previous page
Home IoT & Smart Home

Node-RED Dashboard: Visualise ESP32 Sensor Data Local

Node-RED Dashboard: Visualise ESP32 Sensor Data Local

March 11, 2026 /Posted byJayesh Jain / 0

Node-RED dashboard ESP32 sensor data local visualisation is one of the most powerful combinations available to Indian IoT makers today. Instead of depending on expensive cloud subscriptions or sending your private sensor data to servers abroad, you can build a beautiful, real-time dashboard that runs entirely on your local network — on a Raspberry Pi, an old laptop, or even the ESP32 itself using a small Node.js server. This complete tutorial walks you through every step, from installing Node-RED to building multi-panel dashboards with gauges, charts, and alerts.

Table of Contents

  1. What is Node-RED and Why Use It Locally?
  2. Installing Node-RED on Raspberry Pi / Ubuntu
  3. Programming ESP32 as an MQTT Sensor Publisher
  4. Building the Node-RED MQTT Subscriber Flow
  5. Creating the Dashboard: Gauges, Charts and Text Displays
  6. Adding Alerts and Automation Rules
  7. Multi-Sensor Dashboard: Temperature, Humidity and Pressure
  8. Frequently Asked Questions

What is Node-RED and Why Use It Locally?

Node-RED is an open-source, browser-based visual programming tool developed by IBM and now maintained by the Node-RED project under the OpenJS Foundation. It provides a drag-and-drop flow editor where you connect “nodes” to wire together data sources, processing logic, and outputs — no heavy coding required.

Why run Node-RED locally instead of using cloud dashboards (like ThingSpeak or Blynk)?

  • Privacy: Your sensor data never leaves your premises — critical for home automation, medical monitoring, and industrial applications
  • Speed: Local MQTT broker + Node-RED responds in milliseconds. Cloud round-trips can add 200–2000 ms latency
  • No subscription cost: Free, forever — no limits on data points, update frequency, or number of devices
  • Works offline: No internet dependency — keeps working during BSNL/Jio/Airtel outages
  • Full customisation: Every aspect of the dashboard is configurable

The typical local IoT stack for Indian makers combines: ESP32 (sensor node) → Mosquitto MQTT broker → Node-RED (flow processing) → Node-RED Dashboard (browser UI). All running on a Raspberry Pi 4 or a small Ubuntu server.

DHT11 Temperature And Humidity Sensor Module with LED

DHT11 Temperature And Humidity Sensor Module with LED

This plug-and-play DHT11 module is perfect for your first Node-RED dashboard project — connect to ESP32 and visualise live temperature and humidity data locally.

View on Zbotic

Installing Node-RED on Raspberry Pi / Ubuntu

Node-RED runs on any system with Node.js 18+. Here are installation commands for the most common setups used by Indian makers:

Raspberry Pi (Recommended: Raspberry Pi 4, 2GB RAM)

# Official Node-RED install script for Raspberry Pi
bash <(curl -sL https://raw.githubusercontent.com/node-red/linux-installers/master/deb/update-nodejs-and-nodered)

# Enable autostart on boot
sudo systemctl enable nodered.service
sudo systemctl start nodered.service

Ubuntu / Debian Server

# Install Node.js 20 LTS
curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash -
sudo apt-get install -y nodejs

# Install Node-RED globally
sudo npm install -g --unsafe-perm node-red

# Run as service
npx pm2 start node-red
npx pm2 startup
npx pm2 save

Access the Node-RED editor at http://YOUR_PI_IP:1880 from any browser on your local network.

Install the Dashboard and MQTT Nodes

# From Node-RED editor: Menu → Manage palette → Install
# Or via npm:
cd ~/.node-red
npm install node-red-dashboard
# Dashboard UI available at http://YOUR_PI_IP:1880/ui

Also install Mosquitto on the same machine to serve as your local MQTT broker:

sudo apt install mosquitto mosquitto-clients
sudo systemctl enable mosquitto
sudo systemctl start mosquitto

Programming ESP32 as an MQTT Sensor Publisher

The ESP32 will read sensor data and publish it to the local Mosquitto broker as JSON. Install the PubSubClient and DHT sensor library via Arduino Library Manager.

#include <WiFi.h>
#include <PubSubClient.h>
#include <DHT.h>
#include <ArduinoJson.h>

#define DHT_PIN  4
#define DHT_TYPE DHT11

const char* ssid     = "YourWiFi";
const char* password = "YourPass";
const char* broker   = "192.168.1.100"; // Raspberry Pi IP
const int   port     = 1883;

DHT dht(DHT_PIN, DHT_TYPE);
WiFiClient client;
PubSubClient mqtt(client);

void setup() {
  Serial.begin(115200);
  dht.begin();
  WiFi.begin(ssid, password);
  while (WiFi.status() != WL_CONNECTED) delay(500);
  mqtt.setServer(broker, port);
}

void loop() {
  if (!mqtt.connected()) {
    mqtt.connect("esp32-sensor-node");
  }
  mqtt.loop();

  static unsigned long lastSend = 0;
  if (millis() - lastSend > 5000) {
    lastSend = millis();
    float temp = dht.readTemperature();
    float hum  = dht.readHumidity();

    if (!isnan(temp) && !isnan(hum)) {
      StaticJsonDocument<128> doc;
      doc["temperature"] = temp;
      doc["humidity"]    = hum;
      doc["device"]      = "esp32-node-1";

      char buf[128];
      serializeJson(doc, buf);
      mqtt.publish("home/sensors/dht11", buf);
      Serial.println(buf);
    }
  }
}

Building the Node-RED MQTT Subscriber Flow

Open Node-RED at http://YOUR_PI_IP:1880 and create the following flow:

  1. MQTT In node: Double-click to configure. Set Server to localhost:1883, Topic to home/sensors/dht11, QoS 0, Output: parsed JSON object.
  2. JSON node: Connect after MQTT In. Set Action to “Always convert to JavaScript Object” — this parses the incoming JSON string.
  3. Function node (optional): Extract specific fields and add calculated data:
// Function node: Process sensor data
var data = msg.payload;

// Add heat index calculation
var T = data.temperature;
var H = data.humidity;
data.heatIndex = -8.78469 + 1.61139 * T + 2.3385 * H
               - 0.14612 * T * H - 0.01230 * T * T
               - 0.01642 * H * H;
data.heatIndex = Math.round(data.heatIndex * 10) / 10;
data.timestamp = new Date().toLocaleTimeString('en-IN');

msg.payload = data;
return msg;

Connect the output to multiple dashboard nodes in parallel (fan-out) by wiring from the same output port to multiple destination nodes.

DHT20 SIP Packaged Temperature and Humidity Sensor

DHT20 SIP Packaged Temperature and Humidity Sensor

Upgrade your Node-RED project with the DHT20 — I2C interface, ±0.5°C accuracy, and SIP packaging for reliable long-term monitoring in your local dashboard setup.

View on Zbotic

Creating the Dashboard: Gauges, Charts and Text Displays

With node-red-dashboard installed, you have access to these UI nodes: gauge, chart, text, slider, switch, button, form, notification, and more.

Temperature Gauge

Drag a gauge node from the dashboard palette. Configure it:

  • Group: Create a new group called “Climate Monitor” under a new tab “Home Sensors”
  • Label: Temperature
  • Value format: {{value}} °C
  • Range: min 0, max 50
  • Sectors: 0-20 (blue/cold), 20-35 (green/normal), 35-50 (red/hot)

Connect to the Function node output. In the function node, set msg.payload = data.temperature for this specific output wire. Use a Change node to set msg.payload to msg.payload.temperature for cleaner flow design.

Historical Chart

Drag a chart node and configure:

  • Type: Line chart
  • X-axis: Last 1 hour
  • Y-axis: 0–50
  • Series: Temperature + Humidity (use two lines on same chart)

For multiple series, send a structured payload:

// Function node for chart (dual series)
msg.payload = [
  { "series": "Temperature", "data": [{ "x": Date.now(), "y": msg.payload.temperature }] },
  { "series": "Humidity",    "data": [{ "x": Date.now(), "y": msg.payload.humidity }] }
];
return msg;

Adding Alerts and Automation Rules

Node-RED excels at combining sensor data with logic rules. Here are practical alert examples:

High Temperature Alert (Email or MQTT command)

// Switch node: check temperature > 35
// Property: msg.payload.temperature
// Rule 1: > 35 → wire to notification node + MQTT Out (turn on fan)
// Rule 2: otherwise → wire to nothing (or log)

// MQTT Out node config:
// Topic: home/commands/fan
// Payload: "ON"

Add a notification node (from dashboard palette) to show a pop-up on the dashboard browser, or use the node-red-node-email package to send Gmail alerts when temperature exceeds threshold.

Data Logging to CSV

// Function node: format CSV row
var d = msg.payload;
msg.payload = new Date().toISOString() + "," 
            + d.temperature + "," + d.humidity + "n";
return msg;
// Connect to: File node → /home/pi/sensor-log.csv (append)
BMP280 Barometric Pressure and Altitude Sensor

BMP280 Barometric Pressure and Altitude Sensor I2C/SPI Module

Add altitude and barometric pressure data to your Node-RED multi-sensor dashboard. The BMP280 connects easily to ESP32 via I2C for a comprehensive weather station.

View on Zbotic

Multi-Sensor Dashboard: Temperature, Humidity and Pressure

Once your single-sensor flow is working, expanding to a multi-sensor dashboard is straightforward. Add a BME280 (temperature + humidity + pressure) to your ESP32 and publish all three values in a single JSON packet:

#include <Adafruit_BME280.h>
Adafruit_BME280 bme;

// In loop():
StaticJsonDocument<256> doc;
doc["temperature"] = bme.readTemperature();
doc["humidity"]    = bme.readHumidity();
doc["pressure"]    = bme.readPressure() / 100.0F; // hPa
doc["altitude"]    = bme.readAltitude(1013.25);    // Sea level hPa
doc["device"]      = "esp32-weather-1";
char buf[256];
serializeJson(doc, buf);
mqtt.publish("home/sensors/weather", buf);

In Node-RED, create separate Change nodes to extract each field and connect each to its own gauge, chart, or text widget on the dashboard. Organise the dashboard with tabs for different rooms or sensor types. You can have 10+ ESP32 nodes all publishing to different MQTT topics and a single Node-RED instance visualising all of them simultaneously.

For deploying to multiple devices across your home or office in India, assign static local IPs to each ESP32 in your router’s DHCP settings, and use device-specific MQTT topic paths like home/room1/sensors, home/room2/sensors, etc.

Frequently Asked Questions

Can Node-RED run on an ESP32 directly?

No. Node-RED is a Node.js application and requires significantly more RAM than the ESP32’s 512 KB – 8 MB provides. Node-RED runs on the server side (Raspberry Pi, PC, or cloud VM), while the ESP32 acts as the sensor/actuator node publishing data via MQTT. The minimum practical hardware for running Node-RED is a Raspberry Pi Zero 2W (512 MB RAM) or any Linux system with 256+ MB RAM.

How do I access my Node-RED dashboard from outside my home network?

Several options: (1) Use Ngrok or Cloudflare Tunnel to expose Node-RED temporarily for remote access. (2) Set up a WireGuard or OpenVPN server on your Raspberry Pi so you can VPN into your home network. (3) Use the Node-RED Projects feature with Node-RED Cloud managed hosting. Never expose port 1880 directly to the internet without setting up authentication — go to Node-RED Settings → Security and configure a username/password.

What is the difference between MQTT QoS 0, 1, and 2 in Node-RED?

QoS 0 (at most once) — fire and forget, no acknowledgement. Best for frequent sensor readings where losing an occasional message is acceptable. QoS 1 (at least once) — broker acknowledges receipt; message may be delivered more than once. Good for important data. QoS 2 (exactly once) — four-way handshake ensures delivery exactly once. Slowest but used for critical commands like actuator control. For ESP32 sensor data flowing into Node-RED dashboards, QoS 0 is usually sufficient.

How do I persist Node-RED dashboard data across restarts?

By default, chart history and UI state are lost when Node-RED restarts. To persist data: (1) Use the node-red-contrib-influxdb node to store data in InfluxDB time-series database. (2) Use Node-RED’s built-in context storage with file-backed persistence (configure in settings.js). (3) For simple cases, a File write node to CSV works. InfluxDB + Grafana is the enterprise-grade stack for long-term IoT data visualisation.

Get Started with Your IoT Dashboard Today

Shop ESP32 development boards, DHT sensors, BME280, and all the components you need to build your local Node-RED IoT monitoring system. Fast delivery across India from Zbotic.

Shop IoT Sensors & ESP32 Boards

Tags: ESP32 dashboard, ESP32 sensor data, IoT visualization, MQTT Node-RED, Node-RED
Share Post
  • Facebook
  • Linkedin
  • Whatsapp
ESP32 CAN Bus: Industrial Comm...
blog esp32 can bus industrial communication with sn65hvd230 595582
blog esp32 wrover vs wroom which module should you choose 595594
ESP32 WROVER vs WROOM: Which M...

Related posts

Svg%3E
Read more

IoT Home Insurance Sensor Kit: Leak, Smoke, and Motion

April 1, 2026 0
Table of Contents IoT and Home Insurance Water Leak Detection Smoke and Fire Detection Motion and Intrusion Sensing Building the... Continue reading
Svg%3E
Read more

IoT Pet Tracker: GPS Collar with Geofencing Alerts

April 1, 2026 0
Table of Contents Introduction and Overview Hardware Components Required GPS Module Integration with ESP32 Cloud Platform Setup Real-Time Tracking Dashboard... Continue reading
Svg%3E
Read more

IoT Aquaponics Controller: Fish and Plant Automation

April 1, 2026 0
Table of Contents The Water Monitoring Challenge in India Sensor Technologies for Water Building the Sensor Node Data Transmission and... Continue reading
Svg%3E
Read more

IoT Composting Monitor: Temperature and Moisture Tracking

April 1, 2026 0
Table of Contents Why Temperature Monitoring Matters Sensor Selection Guide Hardware Assembly and Wiring Firmware Development Cloud Data Logging Alert... Continue reading
Svg%3E
Read more

IoT Beehive Monitor: Weight, Temperature, and Humidity

April 1, 2026 0
Table of Contents Why Monitor Beehives Weight Measurement System Temperature and Humidity Sensing Building the Monitor Data Analysis for Bee... Continue reading

Add comment Cancel reply

Your email address will not be published. Required fields are marked

Facebook Twitter Instagram Pinterest Linkedin Youtube

Get the latest deals and more.

Download on Google Play Download on the App Store

Call us: 020 69134444 / 1800 209 0998

Monday - Saturday 09:30 AM - 06:00 PM
For Technical Supports Email: [email protected]
For Sales / Enquiries Email: [email protected]

  • My Account

    • Cart

    • Wishlist

    • Checkout

    • My Orders

    • Track Order

    • My Account

  • Information

    • FAQs

    • Blogs

    • Career

    • About Us

    • Contact Us

    • Payment Options

  • Policies

    • Privacy Policy

    • Terms & Conditions

    • GST Input Tax Credit

    • Shipping Return Policy

    • E-Waste Collection Points

    • Our Sitemap

© Zbotic.in is registered trademark of Moxie Supply Pvt Ltd – All Rights Reserved
Login
Use Phone Number
Use Email Address
Not a member yet? Register Now
Reset Password
Use Phone Number
Use Email Address
Register
Already a member? Login Now