What is the overhead (in bytes) of IoTHub MQTT protocol

Bernard Pletikosa 105 Reputation points
2023-12-14T16:07:25.7733333+00:00

We have a use case for devices connecting via LTE and have a limit on overall monthly network traffic, aiming for as low as possible :) We'll use batching and compression of the payload to reduce network usage from the device side.

When data is sent to IoTHub, using standard SDKs, what is the overhead that is added to each payload (headers and such) needed for IoTHub communications?
From MQTT perspective (based on the docs) is can be max couple of MBs.
We couldn't figure out how much is this for IoTHub layer and hope you can provide that info.

Thanks in advance!

Azure IoT Edge
Azure IoT Edge
An Azure service that is used to deploy cloud workloads to run on internet of things (IoT) edge devices via standard containers.
573 questions
Azure IoT Hub
Azure IoT Hub
An Azure service that enables bidirectional communication between internet of things (IoT) devices and applications.
1,189 questions
0 comments No comments
{count} votes

Accepted answer
  1. Sander van de Velde | MVP 32,556 Reputation points MVP
    2023-12-14T21:36:48.9666667+00:00

    Hello @Bernard Pletikosa ,

    welcome to this moderated Azure community forum.

    This is a good question but a bit hard to answer.

    The IoT Hub behaves like an MQTT broker with a limited, fixed set of topics. These are tightly related to the Device Twin options (desired properties, direct methods, etc.).

    Microsoft offers a calculation for the message size.

    So it would be great to compare the messages with data consumption of the IoT Hub.

    However, the IoT hub counts the number of messages. And these are 4Kb chunks (S1 tier and higher).

    If a 6Kb message arrives, it is counted as two chucks.

    I checked the Metrics and we do not see there any data usage metrics either.

    In conclusion, checking the data consumption of your LTE connection and relating it to the way you send the data seems to be the most reliable way to calculate the data.


    If the response helped, do "Accept Answer". If it doesn't work, please let us know the progress. All community members with similar issues will benefit by doing so. Your contribution is highly appreciated.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.