Crow is a C++ microframework for HTTP and WebSocket services with Flask-like routing, JSON helpers, and optional Mustache templating.
Overview
Crow helps developers build HTTP and WebSocket web services in C++. Routing follows patterns similar to Python Flask, with compile-time type checking for handlers. The framework can run as a header-only dependency, including a single-header distribution option.
Built-in features include JSON read and write support, Mustache-based templates through crow::mustache, middleware hooks, HTTP/1.1 and WebSocket handling, and multipart requests and responses. It targets modern C++11 and C++14 codebases, with async and HTTP/2 support listed as ongoing development goals.
Install paths mentioned on the project site include distribution packages for Linux and macOS, Windows via vcpkg, Conan, and a downloadable header bundle. A minimal program defines routes, sets a port, and runs the server from main.
CrowCpp/Crow continues development from the earlier ipkn/crow codebase under BSD-3-Clause terms, without affiliation to the original author.
Key features
- Flask-style route definitions
- Compile-time type-safe handlers
- Built-in JSON support
- Mustache templating module
- Header-only deployment option
- Middleware extension points
- WebSocket and multipart support
- HTTP/1.1 server core
Use cases
- Embedded HTTP APIs in C++
- WebSocket backend services
- JSON microservices on Linux or Windows
- Small standalone web servers
- Teaching C++ web routing patterns