Introduction: The Data Pipeline Behind Every Smart EV
The intelligence of a connected EV does not live only in the vehicle — it lives in the conversation between the vehicle and the cloud. A battery management system can estimate SoC, track SoH, and compute SoP with high accuracy, but without a reliable communication layer to transmit that data upstream, all of that intelligence stays locked in the vehicle. Fleet operators cannot see it. Analytics platforms cannot process it. Predictive maintenance cannot act on it.
MQTT (Message Queuing Telemetry Transport) is the communication protocol that closes this gap. Originally developed in the late 1990s for monitoring oil pipelines via satellite links — conditions of low bandwidth, high latency, and intermittent connectivity that map almost perfectly to Indian cellular networks — MQTT has become the de facto standard for IoT telemetry across industries from logistics to smart cities. In EV IoT, it is the protocol of choice for transmitting real-time battery data from vehicle to cloud.
This article covers MQTT's architecture in depth for EV IoT. For the broader connectivity landscape — 4G LTE, 5G, V2X, and OTA updates — see the companion article: IoT Connectivity Technologies: Transforming Electric Vehicles and Beyond.
What Is MQTT?
MQTT (Message Queuing Telemetry Transport) is a lightweight, open-standard messaging protocol designed for machine-to-machine (M2M) communication over constrained networks. It was developed in 1999 by Andy Stanford-Clark (IBM) and Arlen Nipper for monitoring remote oil pipelines — environments where bandwidth was scarce, latency was high, and connections dropped unpredictably. These same constraints describe cellular IoT connectivity in many parts of India today.
MQTT operates on a publish-subscribe (pub-sub) architecture rather than the request-response model of HTTP or direct connection model of raw TCP/IP. This architectural difference is the key to its efficiency and scalability for IoT applications. MQTT runs over TCP/IP at the transport layer, inheriting TCP's reliability guarantees while adding the pub-sub abstraction layer that makes it suited for large-scale IoT deployments.
The protocol is governed by the OASIS standard (MQTT v3.1.1 and MQTT v5.0) and is widely supported across all major cloud IoT platforms: AWS IoT Core, Azure IoT Hub, Google Cloud IoT, and specialised EV platforms like the Autoven Platform.
The Publish-Subscribe Model: Decoupling Vehicles from the Cloud
The publish-subscribe model is MQTT's defining architectural choice — and the reason it scales so naturally to large EV fleets. In pub-sub, the devices producing data (publishers) and the systems consuming data (subscribers) never communicate directly with each other. Instead, both connect to a central MQTT broker that routes messages from publishers to subscribers based on topic names.
PUBLISH fleet/autoven/vehicle-001/battery/soc → "62"
PUBLISH fleet/autoven/vehicle-001/battery/temp → "38.4"
PUBLISH fleet/autoven/vehicle-001/location/gps → "12.9716,80.2209"
// Cloud platform subscribes to receive data
SUBSCRIBE fleet/autoven/+/battery/# ← all battery params, all vehicles
SUBSCRIBE fleet/autoven/vehicle-001/# ← all data for vehicle 001
// Broker routes each PUBLISH to all matching SUBSCRIBEs
Vehicle never knows who is listening. Cloud never connects to vehicle directly.
This decoupling has three practical benefits for EV fleet operations:
- Scalability — Adding a new subscriber (a new dashboard, alert service, or analytics engine) requires no changes to the vehicle firmware. The vehicle simply keeps publishing; the new service subscribes to the relevant topics
- Resilience — If the cloud analytics platform goes offline, the vehicle continues publishing. Messages queue at the broker and are delivered when the subscriber reconnects. The vehicle's operation is never dependent on the cloud's availability
- Flexibility — Multiple services can subscribe to the same vehicle data simultaneously: a live fleet dashboard, a fault detection service, a data archiving system, and a predictive maintenance engine — all receiving the same published stream without any coordination required
MQTT vs TCP/IP Direct and HTTP: Why MQTT Wins for EV Telemetry
Understanding why MQTT is the right choice for EV IoT requires understanding what makes TCP/IP direct connections and HTTP polling unsuitable at scale.
| Aspect | TCP/IP Direct | HTTP Polling | MQTT |
|---|---|---|---|
| Message overhead | High (per-connection setup) | 500–1,000 bytes/msg | 2 bytes minimum header |
| Architecture | Point-to-point only | Request-response | Publish-subscribe (1:N) |
| Disconnection handling | Session lost; data lost | Polling gap = data gap | Persistent session; queued delivery |
| Battery/bandwidth cost | High | Very high (repeated headers) | Very low |
| Real-time streaming | Possible but complex | Polling latency | Native push, sub-second |
| Fleet scalability | Server manages N connections | N × polling overhead | Broker handles thousands of clients |
| Offline alerting | No built-in mechanism | No built-in mechanism | Last Will & Testament (LWT) |
MQTT per message overhead : ~5 bytes (2-byte header + topic + small payload)
HTTP daily data (per vehicle) : 800B × 10msg/s × 86,400s = ~691 MB/day
MQTT daily data (per vehicle) : 5B × 10msg/s × 86,400s = ~4.3 MB/day
Fleet of 1,000: HTTP = ~691 GB/day vs MQTT = ~4.3 GB/day (160× saving)
The MQTT Broker: The Heart of EV IoT Architecture
The MQTT broker is the central server that receives all published messages and routes them to matching subscribers. For an EV fleet IoT deployment, the broker is the single most critical infrastructure component — its reliability, throughput, and feature set determine the quality of every downstream analytics, alerting, and monitoring function.
The broker handles several critical functions beyond simple message routing:
- Authentication & authorisation — Verifies that each connecting vehicle is genuine (certificate or token-based) and restricts which topics each device can publish to or subscribe from
- Persistent session management — Stores undelivered messages for offline clients and delivers them when the client reconnects, ensuring zero data loss across network dropouts
- QoS enforcement — Manages acknowledgement and retry logic for QoS 1 and QoS 2 messages, ensuring guaranteed delivery contracts are honoured
- Last Will & Testament (LWT) dispatch — Automatically publishes a pre-configured alert message when a client disconnects without a clean DISCONNECT packet
- Retained messages — Stores the last published value for a topic so new subscribers immediately receive the most recent state without waiting for the next publish event
Eclipse Mosquitto — Lightweight open-source broker, widely used for on-premise deployments. EMQX — High-throughput broker designed for millions of concurrent IoT connections. AWS IoT Core / Azure IoT Hub — Fully managed cloud brokers with built-in security, scaling, and integration with cloud analytics services. Autoven's Platform uses a managed cloud broker optimised for Indian cellular network characteristics.
MQTT QoS Levels: Choosing the Right Delivery Guarantee
MQTT's Quality of Service (QoS) system allows each message to carry an explicit delivery guarantee contract between publisher and broker. Choosing the right QoS level for each data type is a critical design decision in EV IoT architecture — too low risks critical data loss; too high wastes bandwidth and processing on data that does not need it.
For a production EV fleet deployment, the recommended QoS strategy is:
- QoS 0 for high-frequency, non-critical streams: location ping every 5 seconds, voltage snapshots at 10 Hz during normal operation
- QoS 1 for all battery telemetry (SoC, SoH, temperature, current), fault event notifications, and charge session data
- QoS 2 for commands and configuration updates sent to vehicles: remote charge authorisation, speed limit changes, OTA firmware triggers
MQTT Topic Structure for EV Fleet Management
MQTT topics are hierarchical strings that function like addresses for messages — separating levels with forward slashes. A well-designed topic hierarchy is the foundation of a maintainable, scalable EV IoT architecture. Poor topic design creates routing bottlenecks, security gaps, and data management headaches that become very expensive to refactor at scale.
fleet/{fleet-id}/vehicle/{vin}/battery/{parameter}
fleet/{fleet-id}/vehicle/{vin}/location/gps
fleet/{fleet-id}/vehicle/{vin}/fault/{code}
fleet/{fleet-id}/vehicle/{vin}/command/{action}
// Live examples
fleet/avn-mumbai/vehicle/MH01AB1234/battery/soc → "67"
fleet/avn-mumbai/vehicle/MH01AB1234/battery/temp_max → "41.2"
fleet/avn-mumbai/vehicle/MH01AB1234/fault/OV001 → "cell_overvoltage"
// Wildcard subscriptions
SUBSCRIBE fleet/avn-mumbai/+/battery/# ← all battery params, all vehicles
SUBSCRIBE fleet/avn-mumbai/+/fault/+ ← all faults, all vehicles
Two wildcards extend topic matching flexibility:
- + (single-level wildcard) — Matches exactly one topic level.
fleet/+/vehicle-001/battery/socmatches vehicle-001's SoC across all fleets - # (multi-level wildcard) — Matches any number of topic levels from that point forward.
fleet/avn-mumbai/#subscribes to everything from the Mumbai fleet
Persistent Sessions and Last Will & Testament: Built for India's Networks
Two MQTT features are particularly critical for EV deployments in India where cellular coverage can be intermittent: Persistent Sessions and Last Will & Testament (LWT).
Persistent Sessions
When a client connects to the broker with cleanSession=false, the broker retains the client's subscription list and queues any undelivered QoS 1 and QoS 2 messages during the client's absence. When the vehicle reconnects — even hours later — all queued messages are delivered in order. For fleet operators, this means no gaps in the battery health timeline even when a vehicle drives through a dead zone or experiences a cellular handover failure.
Last Will and Testament (LWT)
When a client registers an LWT message at connection time, the broker will publish that pre-configured message to a designated topic if the client disconnects unexpectedly (without sending a proper DISCONNECT packet). For fleet management, LWT enables automatic vehicle-offline alerts without requiring the cloud platform to poll for vehicle absence.
CONNECT {
clientId : "MH01AB1234",
willTopic : "fleet/avn-mumbai/vehicle/MH01AB1234/status",
willMessage: "offline",
willQoS : 1,
willRetain : true
}
// If vehicle drops without DISCONNECT, broker publishes:
fleet/avn-mumbai/vehicle/MH01AB1234/status → "offline"
// Fleet dashboard receives alert immediately → operator notified
Indian urban 3-wheeler fleets commonly experience 3–8 network dropouts per vehicle per day due to handovers between towers in dense city traffic. Without persistent sessions, each dropout creates a data gap in the battery timeline — exactly when high-load stop-go driving is generating the most critical thermal and SoC data. MQTT's persistent session architecture means these dropouts are transparent to the fleet operator: the data arrives intact when the connection resumes.
Security: MQTT over TLS and Device Authentication
Raw MQTT over unencrypted TCP is suitable only for closed, private networks. For EV fleets transmitting over public cellular infrastructure, MQTT over TLS (Transport Layer Security) is mandatory — not optional — to protect battery telemetry, location data, and vehicle identity from interception or tampering.
A production-grade EV IoT security stack combines three layers:
- Transport encryption (TLS 1.2/1.3) — Encrypts all MQTT traffic between vehicle and broker over the cellular link, preventing eavesdropping on battery and location data
- Device authentication (X.509 certificates) — Each AV IoT device carries a unique certificate issued at manufacturing time. The broker validates this certificate on connection, ensuring only genuine Autoven-enrolled devices can publish to fleet topics
- Topic-level authorisation (ACL) — Access Control Lists restrict each vehicle to publishing only to its own topics and subscribing only to topics it is authorised to receive — preventing one vehicle from spoofing another's data
EV telemetry data includes real-time GPS location, driver behaviour patterns, battery health, and fault codes. An unsecured MQTT deployment exposes this data to anyone monitoring the cellular link. Beyond privacy, an attacker with publish access to vehicle command topics could send unauthorised charge commands or disable safety cutoffs. Certificate-based authentication and TLS encryption are non-negotiable for any production EV IoT deployment.
Why MQTT Is Especially Well-Suited to India's EV IoT Reality
India's cellular network landscape is more challenging than the markets where most EV IoT stacks were originally designed. MQTT's design philosophy — assume the network is unreliable, bandwidth is scarce, and connections will drop — maps almost exactly to Indian operating conditions.
Variable 4G Coverage
India's 4G coverage is excellent in metros but variable in tier-2 cities, peri-urban routes, and logistics corridors. EV 3-wheelers and delivery vehicles frequently traverse coverage gaps. MQTT's persistent sessions and offline queuing ensure continuous data collection without requiring the vehicle firmware to implement complex retry logic — the protocol handles it automatically.
SIM Data Cost Sensitivity
For Indian fleet operators managing per-vehicle SIM costs across hundreds of vehicles, MQTT's 160× bandwidth advantage over HTTP is a directly measurable operational saving. A 1,000-vehicle fleet on MQTT pays for approximately 4.3 GB/day of telemetry data instead of ~691 GB/day with HTTP polling — a difference that, at Indian data rates, represents tens of lakhs of rupees annually.
Multi-Operator Fleet Visibility
Many Indian EV fleets operate across multiple cities, states, or ownership structures. MQTT's topic hierarchy naturally maps to this — a single broker can serve multiple fleet IDs, with strict topic-level ACL separating each operator's data while allowing the fleet management platform to subscribe across all fleets for aggregate analytics.
AV IoT by Autoven: MQTT-Powered EV Connectivity for Indian Fleets
Autoven's AV IoT device implements a production-grade MQTT client purpose-built for Indian EV operating conditions. It connects AV BMS telemetry — cell-level SoC, SoH, temperature, voltage, current, fault codes, and GPS — to the Autoven Platform via MQTT over TLS, continuously and reliably, regardless of network conditions.
AV IoT MQTT Capabilities
- MQTT over TLS 1.3 with X.509 certificate-based device authentication — every device uniquely identified
- Persistent sessions with QoS 1 delivery for all battery telemetry — zero data loss across network dropouts
- Last Will & Testament configured at connection — automatic offline alert to fleet dashboard on unexpected disconnect
- Retained messages on key status topics — fleet platform always has current vehicle state on subscription
- Hierarchical topic structure aligned to fleet/vehicle/system/parameter convention
- 4G LTE primary with configurable fallback — network resilience for variable Indian coverage
- Local message buffering on AV IoT device — stores telemetry in onboard memory during extended outages, publishes on reconnect
- OTA firmware updates via MQTT QoS 2 command channel — secure, acknowledged delivery of update triggers
Connect Your Fleet with AV IoT
AV IoT brings real-time battery telemetry from every vehicle in your fleet to the Autoven Platform — reliably, securely, and at a data cost that makes sense for Indian operations. Talk to our team to see how it connects to your EV platform.
Talk to Our Engineers →Conclusion: MQTT Is the Right Protocol for EV IoT — Especially in India
MQTT was designed for exactly the conditions Indian EVs operate in: unreliable networks, constrained bandwidth, and the need for continuous real-time data from thousands of distributed devices. Its publish-subscribe architecture, persistent sessions, QoS guarantees, and minimal overhead make it the only protocol that checks all the boxes for production EV fleet IoT at scale.
The choice of communication protocol is not a detail — it determines data completeness, operational cost, security posture, and the reliability of every analytics function built on top of the telemetry stream. For Indian EV OEMs and fleet operators, MQTT is not a starting point to graduate from — it is the mature, battle-tested standard the industry has converged on for good reason.
- Use MQTT over TLS — Unencrypted MQTT is not appropriate for production EV deployments; certificate-based authentication is the minimum security baseline
- Design a clean topic hierarchy from day one — A well-structured topic tree scales to thousands of vehicles without refactoring; a poorly designed one becomes a permanent technical liability
- Match QoS to data criticality — QoS 0 for high-frequency non-critical streams; QoS 1 for battery telemetry; QoS 2 for commands
- Enable persistent sessions and LWT — These two features eliminate data gaps and enable automatic offline alerting with zero additional application code
- Plan for local buffering on the device — In areas with extended coverage gaps, onboard storage with delayed publish is the last line of defence for telemetry continuity
MQTT handles the messaging layer — but it runs on top of a broader connectivity stack. For a complete guide to 4G LTE, 5G, V2X, and OTA update technologies for EVs, read: IoT Connectivity Technologies: Transforming Electric Vehicles and Beyond.