What is the max message size in MQTT?
An MQTT message can have a maximum size of 256 MB in a single publish. But in most cases, they are smaller than 1 MB. A common file size is less than 10 KB.
There are several reasons why it makes sense to keep messages small. One reason is, you can not retry sending a message. For example, you try to send 250 MB. At 200 MB you experience a connection abortion. This means you will have to send the whole message again.
👉 Crunching and compression are good practices to reduce file size. For detailed information read the HiveMQ documentation: https://bit.ly/3gvXK1N
While MQTT allows a message size up to 256 MB, many cloud providers have tight limits and do not support the maximum file size. So for professional use cases, it is important to choose your MQTT broker wisely. HiveMQ allows the configuration of a file size limit.
👉 To learn about MQTT in detail, read our MQTT Essentials blog series: https://bit.ly/3gbfDTc
👉 We have a comprehensive 11-part video series about MQTT Essentials.
• MQTT Essentials
👉 We also explain the core of MQTT concepts, its features, and other essential information on the HiveMQ blog: https://bit.ly/3F7l2pm
👉 Get your own MQTT Essentials in a comprehensive, free E-Book: https://bit.ly/3D17jhJ
👉 To know about HiveMQ: https://bit.ly/3ooK4uc
Subscribe to our HiveMQ channel to get video updates. Hit the subscribe button above or subscribe to our newsletter (https://bit.ly/3os4nqr) to keep up to date on the latest MQTT news.
#MQTT #MQTTFAQs #IOT