News & Articles Articles

The Protocol That Changed the Way We Communicate: Secrets of MQTT

Yuri Chamarelli 06 July 2021 6 min. read
396 views 0 comments LoadingSave

“The Internet of Things is a system of interrelated computing devices, mechanical and digital machines, objects, animals or people that are provided with unique identifiers and the ability to transfer data over a network without requiring human-to-human or human-to-computer interaction,” or thus says Wikipedia. The question is simple—how does it do that? If the Internet of Things is a system of interrelated devices all chattering away, exactly how do they communicate?

Taking the IoT one step further, the Industrial Internet of Things encompasses all the information being used in factories and other manufacturing settings to improve quality and efficiency. How it’s all happening, though, is an interesting question, especially for those of us who are not directly involved in the field.

The key, it turns out, is called MQTT. All those messages flowing from here to there is made possible by this “messaging protocol.” Let’s take a closer look and find out how MQTT enables the IoT to run.

What is MQTT?

MQTT Debug

At its beginnings, MQTT stood for Message Queuing Telemetry Transport, a standardized set of rules—also known as a protocol—for moving packets of information among electronic devices. Those devices don’t have to be manufactured by the same company because the protocol is universally compatible. This ensures, for example, that your friend with the iPhone can message you, the Android user.

As you can imagine, these protocols are an important part of the digital world, and they do their work in the background where most users aren’t even aware of them. There are four basic categories of protocols, but the one we are concerned with here is the transport protocol, the final “T” in MQTT. This set of rules is concerned with how packets of information are sent, received, and confirmed. The other protocols that are not as applicable within IIoT perform functions like moving information through wired or wireless networking or managing Internet communication.

To give credit where credit is due, MQTT was invented in 1999 by Dr. Andy Stanford-Clark of IBM UK and Arlen Nipper, formerly of Eurotech and now with Cirrus Link Solutions. That original version of MQTT was developed for use in the oil and gas industry, a great example of an industry that benefits from the Industrial Internet of Things; all those pipelines must integrate and work together to be efficient. Today, MQTT is no longer an acronym primarily because it no longer uses traditional message queues.

Why is MQTT used? 

The IT infrastructure is made up of millions of electronic devices manufactured by hundreds of vendors. Consider how many such devices you use yourself in the course of a day (both at home and at work), then multiply that to encompass thousands of businesses worldwide. You can understand how powerful—and important—the flow of information can be.

MQTT was created by Stanford-Clark and Nipper to provide a pathway for all those machines to talk to each other and exchange information. As we saw earlier, they developed MQTT originally so oil pipelines could communicate via satellite connections, and they made it as user-friendly as possible by writing code that used limited bandwidth. According to software consulting company Knoldus, the term “lightweight” is often used to describe MQTT, meaning it is “……open, simple, and designed so as to be easy to implement.” And because it is lightweight, more devices use it so the sheer amount of data being monitored or controlled is larger.

MQTT is bidirectional, allowing data to be sent to and from a device. And if a device loses its connectivity, all clients along the pathways will be notified using a procedure called the Last Will and Testament function. Much like receiving an “away” message when you send an email to your friend you didn’t know was on vacation, this feature lets a plant manager, for example, know what’s going on. They can then adjust schedules, inventory, and anything else that might be impacted by the interruption. 

Where is MQTT used?


We have seen that MQTT was originally developed for use in the oil and gas industry, but most of us aren’t involved in those businesses on a daily basis. So how is MQTT relevant to us, if at all?

Actually, yes, and that will probably increase even more in the future. Let’s face it: when Amazon and Facebook use anything, the world sits up and notices. Facebook Messenger works because of MQTT moving all those packets of data so we can type those instant messages and send documents and pictures, and Amazon Web Services’ system is based on MQTT too.

Some specific populations are reaping the benefits of MQTT as well. What if you were traveling and couldn’t hear the announcements being made over the PA system? Some students at IBM developed a system to deliver that packet of data directly to the mobile phone of any subscriber who is deaf or hard of hearing. The plan is to extend that usage to other busy public places like train stations and hospitals that rely on public address systems.

Another example is Leafy Green Machine, a business that creates hydroponic farms inside repurposed freight containers. LGM uses MQTT to connect its 100+ locations. And OwnTracks, yet another beneficiary of MQTT, is an app for smartphones that uses MQTT to monitor a phone’s location and updates info as the user moves. These types of focused uses appear to be growing all the time.

The Future of MQTT

According to a recent article in Inductive Automation, experts in the world of digital communicationsay that “overall, MQTT appears to be the protocol best suited for the control system used by an industrial organization, and we can expect that its rapid rate of adoption will only increase in the future.” Smart lighting systems, smart temperature controls in new homes, and countless other applications will impact the public. More and more IIoT uses of MQTT will be working in the background, making various industries work more efficiently. This ultimately benefits all of us as companies create products and offer services faster and cheaper than ever before. 

Yuri Chamarelli
396 views 0 comments LoadingSave


Please login/register to comment


Leave a Reply

Never miss a new article
Sign up for the newsletter
Never miss news about PLCnext Technology
Get interesting content via newsletter four times a year
Receive exclusive information before all other users