
An IoT platform is not one product. It is five layers, and the expensive mistakes happen when someone picks tools for one layer without checking they fit the others — a broker that cannot scale to the device count, a database that cannot answer time-range questions, a dashboard that polls an API the ingestion layer never writes to. This post walks the layers in order, says what each one decides, and shows how the decisions connect. It describes the architecture we use for real-time dashboards, at the level you can reuse for scoping your own product.
Layer 1 — Devices and connectivity
Everything starts with what the device can do: which radio it has (WiFi, LTE, LoRa, NB-IoT), how it is powered, how often it must report, and whether anyone can update its firmware in the field. Those constraints pick the transport — the MQTT vs HTTP decision we cover separately — and they set the message budget for everything downstream: a device reporting every 5 seconds produces 17,280 messages per day, and a thousand of those devices produce 17 million.
Two decisions at this layer are routinely skipped and always regretted:
- Firmware updates from day one. The first bug fix after deployment costs more than the entire OTA mechanism, if you have to recall hardware instead.
- Device identity as a first-class thing. A unique ID and per-device credentials provisioned at manufacture, not a shared password printed in the assembly manual. Revocation — "this serial number no longer talks to us" — must be possible from your side without touching the hardware.
Layer 2 — Ingestion
Ingestion is the front door: a broker (typically MQTT) or an HTTPS endpoint that authenticates devices and accepts their messages. Three jobs belong here:
- Authentication and ACLs. Per-device credentials, and topic permissions so one compromised unit cannot publish into another product's stream.
- Normalization. Devices in the field for years will run firmware variants; the ingestion layer maps their payload variants into one internal event shape, so downstream code never learns about hardware revisions.
- Backpressure. When a thousand devices reconnect after a network outage, the queue must absorb the burst instead of dropping or overloading the storage layer. This is where MQTT's QoS and session queues earn their place.
A small rule that saves real money: stamp events with a server-side receive time even though devices include their own timestamp. Device clocks drift; when you later ask "what actually happened in that hour", you want both.
Layer 3 — Storage
Telemetry is time-series data, and time-series data breaks general-purpose databases in predictable ways: writes arrive continuously and out-of-order compensation is constant, retention matters (do you need raw readings from 18 months ago, or just aggregates?), and the queries that matter are always "this device, this time range, this metric".
The pattern that holds up in practice:
- A time-series store for readings — TimescaleDB, InfluxDB or similar — with retention policies and automatic downsampling: raw data for recent windows, hourly or daily aggregates kept long-term.
- A relational store for state — devices, customers, sites, assignments, and anything that changes by update rather than by append. Postgres for most products.
- A message bus between ingestion and everything else — so that one event from a device can simultaneously update the live dashboard, feed the alerting engine and land in storage, without those three knowing about each other.
The storage decision is also the billing decision: retention times and downsampling intervals are the difference between a 40 GB and a 4 TB database for the same fleet.
Layer 4 — Commands: the return path
A dashboard that only displays is half a platform. Almost every real product needs the opposite direction: set a threshold, restart a device, open a valve, change a reporting interval. The command path deserves the same engineering as telemetry, because it is the dangerous direction:
- Commands should be explicit request/response where possible — the platform publishes a command message, the device acknowledges execution, the UI shows "applied at 10:32", not "sent".
- Commands must be authenticated and audited — who told the fleet to restart, when, from which account. This is the layer an auditor will ask about first.
- Offline devices need queued or forbidden semantics, chosen deliberately. "Deliver when it reconnects" is right for a config change and wrong for "open the valve" — for actions with physical consequences, you usually want to refuse commands to offline devices rather than execute them late and unattended.
Layer 5 — Presentation and alerting
The dashboard is the layer everyone sees, and the one where generic tools get tried first. The honest split, which we cover in detail in the dashboard vs BI comparison: BI tools are excellent for historical exploration and reports; a custom real-time dashboard is justified when operators need live state, command controls, and role-specific views in one screen.
Alerting belongs to this layer and is designed around one question: what does a human need to do? An alert without a response path is noise. Rules that survive contact with operations are thresholds on computed states (device offline for more than X minutes, reading outside range for more than Y consecutive samples — not a single out-of-range blip), routed to the person who can act, with deduplication so a fleet-wide outage produces one alert, not four thousand.
How the layers connect — and where projects go wrong
The failure patterns we see most, mapped to their layer:
- Ingestion chosen without storage in mind → a broker burst melts an unprepared database on the first fleet reconnect.
- Storage chosen without queries in mind → the team stores everything raw and then cannot answer "average per hour per site" without a batch job.
- Commands bolted on at the end → the return path shares no authentication with the telemetry path, and the audit question has no answer.
- Dashboards built before the event model settled → three rebuilds in the first six months.
The sequence that avoids all four: settle the message model (what an event is, its topic scheme, its internal shape) first — it is the contract between every layer — then build ingestion and storage against it, then the command path, then the dashboard.
Where to go next
If you are still deciding how devices should talk to the platform, start with MQTT vs HTTP for IoT. If the layer-5 question is "build or buy", the real-time dashboard vs BI tool comparison covers it. And if you want this mapped onto your actual device list and data source — the most useful form of scoping conversation for a connected product — that is where our IoT development work starts.
FAQ
What are the layers of an IoT architecture? Commonly: devices and connectivity, ingestion (broker/API), storage (time series plus relational state), a command path back to devices, and presentation (dashboards, alerting). The names vary; the responsibilities do not.
Do I need a time-series database for IoT? Not always, but telemetry volume and time-range queries are what time-series stores are built for. Below a few thousand messages per day, a ordinary Postgres table with good indexes is fine — and simpler to operate.
What should I design first in an IoT platform? The message model: what an event is, how it is addressed (topics), and its shape. Every other layer consumes or produces that contract, so getting it right first prevents the expensive mismatches later.
Have a project idea?
Get a rough estimate in 5 minutes with our Project Scoper.
Scope Your ProjectReady to discuss?
30 minutes. No pitch deck. Just an honest conversation about your project.
Book a Free Call





