// the find
eclipse-paho/paho.mqtt.c
An Eclipse Paho C client library for MQTT for Windows, Linux and MacOS. API documentation: https://eclipse-paho.github.io/paho.mqtt.c/
The reference C client library for MQTT, maintained under the Eclipse Paho umbrella. Supports MQTT 3.1.1 and 5.0, with both synchronous (MQTTClient) and asynchronous (MQTTAsync) APIs. If you're writing C or need a C-linkable library for embedded or systems work, this is the one you reach for.
Full MQTT 5.0 support including properties and reason codes, which many alternative C clients still lack. Four distinct library variants (sync/async × plain/TLS) let you pick exactly what you link against rather than pulling in OpenSSL when you don't need it. The musl/static build support is genuinely useful for embedded Linux targets — you get a single binary with no runtime dependencies. CMake export targets are done correctly: namespaced, with static variants named separately, so downstream CMakeLists.txt files don't have to guess.
The CI badges in the README still point to Travis CI and LGTM, both of which are dead — actual CI has moved to GitHub Actions workflows but the README hasn't caught up, which is a bad first impression. The synchronous MQTTClient API blocks the calling thread during network I/O with no timeout granularity beyond what you set at connect time; if your broker goes away mid-publish you will block for the full keepalive interval. Windows support is second-class: Unix-domain sockets are explicitly unavailable, and the build toolchain documentation assumes Linux tooling. Thread safety is documented at the API level but the internal locking strategy isn't exposed, so you can't reason about contention if you're sharing a client across threads.