Introduction

Mongoose is a production-grade embedded web server and networking library for C and C++. It lets you build secure web interfaces, device dashboards, and cloud-connected firmware on microcontrollers and embedded devices.

The library provides HTTP, WebSocket, TLS/HTTPS, MQTT, and OTA firmware updates in a compact two-file C/C++ library. Its event-driven, non-blocking architecture works well on resource-constrained systems and supports real-time communication and secure networking.

Mongoose runs on Windows, Linux, and macOS during development, and targets embedded platforms such as STM32, NXP, RP2350, ESP32, and other Cortex-M and RISC-V microcontrollers. It can run on any RTOS or on bare metal.

You can integrate Mongoose with existing networking stacks such as lwIP, Zephyr, or NetX. Alternatively, use the built-in TCP/IP and TLS stacks and run networking without any external dependencies.

Mongoose is open source and hosted on GitHub, with more than 12,000 stars - the most popular embedded web server library in its category. Since 2004 it has powered thousands of commercial and open-source products, and it even runs on the International Space Station. If it is good enough for NASA and thousands of companies building connected devices, it will work well for your project too.

Key features

  • Embedded HTTP server for device web interfaces and REST APIs
  • WebSocket support for real-time dashboards and telemetry streaming
  • MQTT client and server for cloud connectivity
  • Built-in TLS / HTTPS stack - or integrate with
  • Built-in TCP/IP stack - or integrate with lwIP, Zephyr, or NetX
  • Runs on any RTOS or directly on bare metal
  • Compact two-file C/C++ library - mongoose.c and mongoose.h
  • Built-in OTA firmware update support
  • Cross-platform - works on Windows, Linux, macOS, and microcontrollers
  • Web UI Builder for quickly building device dashboards
  • Security-focused design and support for EU CRA compliance
  • Commercial support available directly from the authors

See full list of features at Mongoose Features.

Create your first device dashboard

To get started quickly, try Web UI Wizard - a visual Web UI builder that generates a complete device dashboard and networking code without requiring frontend expertise.

Continue with the next section to set up the build environment and run your first web server.