Built to order

LPG Gas Leakage Detector with Telegram Alert

An LPG gas-leakage detector built on ESP32 with an MQ-2 sensor that sounds a buzzer, switches on an exhaust fan via relay, and pushes instant Telegram alerts to your phone when gas concentration crosses the danger threshold — low cost, high safety relevance, and a long-tail SEO gem.

Illustrative render of the LPG Gas Leakage Detector with Telegram Alert prototype.
More project photos (2)

The problem

Gas leaks cause some of the most preventable household accidents in India. This gas leakage detector project using ESP32 continuously monitors LPG concentration with an MQ-2 sensor and responds automatically: a local buzzer raises an alarm, a relay switches on an exhaust fan to ventilate the area, and an instant Telegram message reaches your phone wherever you are. Built on the ESP32's built-in Wi-Fi, it needs no extra GSM module and works with any home router. A compact, low-cost, high-safety-relevance build — ideal as a final year project for ECE, EEE, and electronics diploma students, with complete report, source code, and viva support included.

How it works

  1. The MQ-2 sensor's tin-dioxide sensing element changes resistance in the presence of combustible gases (LPG, methane, propane, smoke).
  2. The ESP32 samples the sensor's analog output every few seconds, smooths the readings, and maps them to a gas-concentration value.
  3. When the value crosses the danger threshold: the buzzer sounds, the relay energizes the exhaust fan, and the ESP32 sends a pre-formatted alert to your Telegram bot.
  4. Once gas levels fall back below the threshold, the system sends an "all clear" message and returns the fan and buzzer to standby.

Project features

  • MQ-2 semiconductor gas sensor calibrated for LPG detection with adjustable sensitivity via onboard potentiometer
  • ESP32 reads analog gas levels continuously and compares against a configurable danger threshold
  • Loud local buzzer alarm triggers the moment the threshold is crossed
  • Relay automatically switches on an exhaust fan (or ventilation system) to disperse leaked gas
  • Instant Telegram alert messages sent to your phone via Telegram Bot API on leak detection and on all-clear
  • Status LED indication for normal, warning, and leak conditions
  • Calibration mode with serial monitor readout to set the right baseline for your room
  • Low component cost — total hardware under typical academic project budgets

What is included

  • Assembled hardware unit (sensor wired and tested)
  • Complete firmware source code (Arduino IDE) with configurable thresholds and Wi-Fi/Telegram credentials
  • Wiring diagram and circuit explanation
  • Report PDF: abstract, block diagram, methodology, results, conclusion
  • PPT presentation for project review
  • Viva Q&A document with expected questions and answers

Limitations & prerequisites

  • Requires a working Wi-Fi connection for Telegram alerts; local buzzer and fan work without internet
  • MQ-2 detects gas presence, not exact concentration — readings are indicative, and the sensor needs ~1–2 minutes of warm-up after power-on
  • The sensor should be mounted near floor level, since LPG is heavier than air — mounting height affects sensitivity
  • This is an academic safety demonstration, not a certified commercial gas-safety product
Components & software requirements
  • ESP32 development board (built-in Wi-Fi)
  • MQ-2 gas sensor module
  • Active buzzer (5V)
  • Single-channel relay module
  • Exhaust fan (12V DC) or equivalent load
  • LEDs and current-limiting resistors
  • Breadboard / PCB, jumper wires, 5V power supply

Download abstract (PDF)

Related guides

All guides
Blueprint-style technical illustration of rectifier circuits, AC-to-DC waveforms, diodes and a capacitor on an electronics benchElectronics students who can read a basic schematic and want the diode circuits behind every power supply as workshop tools, not textbook diagrams.

Rectifiers, Clippers and Clampers: The Diode Circuits Behind Every Power Supply

Every power supply hides the same trick: diodes forcing AC to flow one way, and a capacitor smoothing the pulses into DC. This guide explains half-wave and bridge rectifiers with real numbers, shows how to size the filter capacitor with one formula, and covers clipper and clamper circuits — the diode techniques behind input protection, DC restoration and voltage multipliers — plus a bench build you can measure yourself.

Read guide
Blueprint-style technical illustration of an ESP32 development board at the centre, with sensor nodes, data-flow arrows and a circuit-brain motif representing an AI agent reasoning and sending decisions back.Engineering students building IoT or embedded final-year projects who want to add local AI agent behaviour with ESP32, MQTT and a small language model.

AI Agents on ESP32: Agentic IoT Final-Year Projects

An agentic IoT system observes, reasons, acts, remembers and explains. On ESP32 that means a split architecture: the chip senses and acts while a small local model (Ollama on your laptop) reasons over MQTT — a full LLM needs gigabytes of RAM the chip doesn't have. This guide covers three working patterns (host-reasoned agent, on-device tinyML on ESP32-S3, and a hybrid of both), plus Wi-Fi CSI presence sensing, parts and budget for India, code shapes, and honest limits to state in your report.

Read guide
Technical illustration of three electronic control units linked by a twisted-pair CAN bus cable carrying signal pulses between them.Electronics, E&TC, IoT and robotics students who keep hearing “CAN bus” in EV, automotive and industrial project ideas and want to understand it properly before wiring anything

CAN Bus Basics for Students: How ECUs Communicate

CAN bus is the shared network that lets dozens of controllers in a car, EV or robot communicate over two wires. This guide explains message IDs, arbitration, the physical layer, frame structure, error handling and CAN FD, then walks through building a working two-node bench network with an ESP32 and a transceiver.

Read guide
Get a quotation