awesome-repositories.com
Blog
MCP
awesome-repositories.com

Discover the best open-source repositories with AI-powered search.

ExploreCurated searchesOpen-source alternativesSelf-hosted softwareBlogSitemap
ProjectMCP serverAboutHow we rankPress
LegalPrivacyTerms
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
dotnet avatar

dotnet/MQTTnet

0
View on GitHub↗
4,949 stars·1,145 forks·C#·mit·30 views

MQTTnet

MQTTnet is a comprehensive MQTT library for .NET that supports both client and broker roles in a single codebase. It provides a full-featured broker implementation capable of hosting a server with access control, message interception, session persistence, and support for mixed MQTT protocol versions. The client side offers robust publish-subscribe communication with automatic reconnection that preserves quality-of-service guarantees, ensuring reliable message delivery across network interruptions.

The library distinguishes itself with a plugin-based authentication pipeline for validating client credentials and a message interception system that allows custom processing of every published message. It includes TLS encryption for protecting data in transit, protocol-version negotiation to adapt to different client capabilities, and a QoS-aware retransmission engine that guarantees exactly-once and at-least-once delivery. The broker supports broker-side message publishing, client disconnection, and clean session management.

MQTTnet covers the full MQTT capability surface including connection establishment, topic subscription, message publishing, incoming message handling with detailed acknowledgments, and a unified communication framework that wraps multiple transport protocols with automatic reconnection and message queuing. The library's session-state persistence stores client subscriptions and missed messages across restarts, enabling durable messaging patterns. Its asynchronous TCP socket model handles thousands of concurrent connections without blocking threads, making it suitable for high-throughput scenarios. The documentation and install surface are available through the project's GitHub repository and NuGet packages.

Features

  • Dual-Role Libraries - A full-featured MQTT library for .NET that supports both client and broker roles with message routing and session management.
  • MQTT Clients - Sending and receiving messages to an MQTT broker with topic-based publish/subscribe, including automatic reconnection.
  • MQTT Broker Connections - Provides TCP connection establishment and protocol version negotiation for MQTT broker communication.
  • Resilient Connections - Maintaining reliable MQTT communication with automatic reconnection and message queueing to handle network interruptions.
  • MQTT Message Brokers - Starts a server that listens for TCP connections, routes messages, manages client sessions, subscriptions, retained messages, and supports mixed protocol versions.
  • Access Control Modules - Enforcing authentication and authorization on MQTT client connections and subscriptions to secure the messaging system.
  • Access-Controlled Brokers - Hosts a broker that validates client credentials, enforces subscription rules, and stores retained messages for topic-based publish-subscribe.
  • Non-Blocking TCP Servers - Manages network I/O with non-blocking sockets to handle thousands of concurrent connections without blocking threads.
  • MQTT Message Handlers - Processes incoming MQTT messages asynchronously via callbacks for custom application logic.
  • Publishers - Publishes messages to MQTT topics with configurable quality-of-service levels.
  • Topic Subscribers - Subscribes to MQTT topics with support for wildcards and configurable quality-of-service.
  • QoS Retransmission Engines - Guarantees exactly-once and at-least-once delivery by tracking packet IDs and retrying with flow control.
  • Messaging Session Persistence - Stores client subscriptions and missed messages across restarts by serializing session data to a configurable storage backend.
  • Transport Wrappers - Wraps raw TCP streams with encryption using configurable certificates and cipher suites for secure communication.
  • MQTT TLS Encryption - Encrypting MQTT traffic over TLS to protect data in transit between clients and the broker.
  • Broker-Initiated Publications - Injects a message directly from the broker into the topic tree, as if a client published it.
  • QoS-Guaranteed Reconnections - Reconnects and resends messages with correct QoS to maintain reliable communication with the broker.
  • QoS-Preserving Reconnections - Automatically reconnects and retransmits messages with correct quality-of-service to maintain reliable communication with the broker.
  • MQTT Message Acknowledgements - Sends detailed acknowledgements with reason codes and user properties for received MQTT messages.
  • MQTT Version Detectors - Detects the MQTT version in the CONNECT packet and adapts packet parsing and feature support accordingly.
  • Message Interceptors - Routes every published message through user-defined interceptors before delivery to subscribers or retained message store.
  • MQTT Credential Validators - Validates client credentials during MQTT connection handshake and rejects unauthorized clients.
  • Client Credential Validators - Validates client credentials through configurable handlers that can reject connections with custom reason codes.
  • MQTT Communication - High-performance library for MQTT clients and brokers.

Star history

Star history chart for dotnet/mqttnetStar history chart for dotnet/mqttnet

How this analysis was created: This summary and feature list are AI-generated from collected project material and can contain mistakes. Stars, license and language are imported from GitHub. Inclusion does not mean that we have tested or audited this project. Check the source documentation for any feature you depend on. Learn more on our About page.

AI search

Explore more awesome repositories

Describe what you need in plain English — the AI ranks thousands of curated open-source projects by relevance.

Start searching with AI

Projects sharing features with MQTTnet

These projects share indexed features with MQTTnet. Shared tags can include platform or build tooling; verify the primary use case before treating a result as a replacement.
  • mcxiaoke/mqttmcxiaoke avatar

    mcxiaoke/mqtt

    5,195View on GitHub↗

    This project provides a technical specification and reference manual for the MQTT 3.1.1 standard, serving as a translated Chinese guide for implementing this lightweight IoT messaging protocol in resource-constrained device networks. The documentation covers the fundamental mechanisms of the publish-subscribe model, including topic-based routing with wildcard filtering, retained message storage, and the configuration of last will and testament messages. It details the protocol's approach to reliability through various quality of service levels, ranging from single-level acknowledgments to exa

    Rich Text Formatmqtt
    View on GitHub↗5,195
  • chkr1011/mqttnetchkr1011 avatar

    chkr1011/MQTTnet

    5,011View on GitHub↗

    MQTTnet is a .NET library providing a framework for implementing MQTT clients and brokers. It includes a broker implementation for hosting a central message hub that routes messages between connected clients and a client library for publishing and subscribing to messages. The project supports both TCP and WebSocket transport layers, enabling secure data traffic through transport layer security. It allows for the development of custom middleware to intercept, transform, or validate messages as they pass through a server. Capability areas include distributed message routing, persistent connect

    C#
    View on GitHub↗5,011
  • eclipse-paho/paho.mqtt.ceclipse-paho avatar

    eclipse-paho/paho.mqtt.c

    2,323View on GitHub↗

    This project is a cross-platform C library designed for implementing MQTT messaging in applications. It serves as an asynchronous networking toolkit that enables resource-constrained systems and distributed components to exchange telemetry data and control signals with messaging brokers. The library distinguishes itself through a state-machine-based protocol handler that manages connection lifecycles and persistent session states, ensuring reliable message delivery even during intermittent network connectivity. It utilizes a background thread to manage network operations, allowing application

    Ceclipse-pahoeclipseiotinternet-of-things
    View on GitHub↗2,323
  • emqx/mqttxemqx avatar

    emqx/MQTTX

    4,802View on GitHub↗

    MQTTX is a cross-platform MQTT client application designed for testing, debugging, and managing MQTT brokers. It supports both MQTT v3.1.1 and v5.0, enables simultaneous management of multiple broker connections, and provides an interactive chat-style interface for publishing and subscribing with configurable quality of service, payload transformation, and topic visualization. The client can be used as a desktop application, a command-line tool, or a self-hosted web client deployable via Docker. What sets MQTTX apart is its integration of AI-assisted workflows, allowing users to generate MQTT

    TypeScriptclicross-platformelectron
    View on GitHub↗4,802
Compare all 30 related projects→

Frequently asked questions

What does dotnet/mqttnet do?

MQTTnet is a comprehensive MQTT library for .NET that supports both client and broker roles in a single codebase. It provides a full-featured broker implementation capable of hosting a server with access control, message interception, session persistence, and support for mixed MQTT protocol versions. The client side offers robust publish-subscribe communication with automatic reconnection that preserves quality-of-service guarantees, ensuring reliable message delivery…

What are the main features of dotnet/mqttnet?

The main features of dotnet/mqttnet are: Dual-Role Libraries, MQTT Clients, MQTT Broker Connections, Resilient Connections, MQTT Message Brokers, Access Control Modules, Access-Controlled Brokers, Non-Blocking TCP Servers.

Which projects share features with dotnet/mqttnet?

Projects with overlapping indexed features include: mcxiaoke/mqtt — This project provides a technical specification and reference manual for the MQTT 3.1.1 standard, serving as a… chkr1011/mqttnet — MQTTnet is a .NET library providing a framework for implementing MQTT clients and brokers. It includes a broker… eclipse-paho/paho.mqtt.c — This project is a cross-platform C library designed for implementing MQTT messaging in applications. It serves as an… emqx/mqttx — MQTTX is a cross-platform MQTT client application designed for testing, debugging, and managing MQTT brokers. It… eclipse/mosquitto — Mosquitto is an MQTT message broker and IoT messaging server designed to route data between publishers and… ag2ai/faststream — FastStream is an asyncio message broker framework for building event-driven applications in Python. It provides a…