Maker.io main logo

Real-Time IoT Smart Energy Meter with SMS Alerts

115

2026-02-03 | By Rinme Tom

License: General Public License Breadboards Jumper Wires Arduino ESP32

๐Ÿ“˜ Summary

In this Maker project, youโ€™ll build a Smart Energy Meter using IoT and an ESP32 microcontroller and a PZEM-004T energy sensor to monitor electrical parameters like voltage, current, power, power factor, and energy consumption in real time. Data is transmitted to a cloud dashboard via MQTT, and critical electrical anomalies trigger automated SMS alerts โ€” providing safer, smarter energy monitoring for residential, commercial, and industrial applications.

PZEM-004T energy sensor

๐Ÿง  Why This Project Matters

Traditional energy meters only record total usage and require physical readouts. With this IoT smart energy meter, you can:

  • Track power usage remotely from anywhere with internet access.

  • Visualize data live on an MQTT web dashboard.

  • Receive SMS alerts for abnormal electrical conditions like over-voltage or excessive current.

  • Use the system as a foundation for advanced automation (e.g., load control, efficiency reporting).

Block Diagram

๐Ÿ“Š How It Works: System Architecture

This IoT smart energy meter combines local measurement, cloud publishing, and alerting:

๐Ÿงฉ Core Flow

  1. Measurement:
    The PZEM-004T measures electrical parameters using internal sensors and a current transformer (CT clamp).

  2. Processing:
    The ESP32 reads PZEM data over UART (Modbus Protocol), formats it, and prepares it for transmission.

  3. Remote Publishing:
    Data is sent via Wi-Fi to an MQTT broker and displayed on a remote dashboard in real time.

  4. Alerts:
    When predefined thresholds (e.g., high voltage) are exceeded, an SMS alert is sent using a cloud API.

Circuit Diagram

๐Ÿ“ˆ Real-Time Dashboard

A lightweight web dashboard visualizes:

  • Voltage (V)

  • Current (A)

  • Active Power (W)

  • Cumulative Energy (kWh)

  • Frequency (Hz)

  • Power Factor

It connects to the MQTT broker using WebSockets and updates values instantly as new data arrives.

Dashboard

๐Ÿ“ฑ SMS Alerts: Stay Notified

This project integrates with a free SMS API via a cloud service so that when thresholds like over-voltage or overload are detected, the registered mobile number receives an automated alert. The system checks conditions in the ESP32 code and only sends messages when necessary to avoid spam.

SMS

โšก Practical Use-Cases

This IoT smart energy meter is ideal for:

โœ” Real-time home energy monitoring
โœ” Safety alerts for faulty wiring or dangerous conditions
โœ” Remote power management for vacation homes or remote installations
โœ” Base for smart home automation integrations (e.g., Home Assistant, Node-RED)

Working Demo

๐Ÿ” Tips for Success

  • Ensure the CT clamp only encircles the live conductor โ€” not both live and neutral.

  • Validate I2C addresses if the LCD shows no output (commonly 0x27 or 0x3F).

  • Use a secure MQTT broker if deploying in a production environment.


๐Ÿ Conclusion

This project combines embedded systems, IoT communication, and real-time alerting into an accessible smart energy meter solution. With just a few components and open tools like the Arduino IDE and MQTT, you can transform raw electrical data into meaningful insights and actionable alerts โ€” empowering smarter, safer energy usage.

Have questions or comments? Continue the conversation on TechForum, DigiKey's online community and technical resource.