Quill: A C++17 Logger Where the Calling Thread Only Encodes Arguments and a Backend Worker Does the Formatting
Ultra-low-latency asynchronous C++17 logging and metrics library for performance-critical applications
At a glance
- What is it?
- Quill is an asynchronous C++17 logging and metrics library built to keep formatting and I/O off latency-sensitive threads. Its trade-offs are explicit: a macro API for speed, a function API for readability, and options split between compile time and runtime.
- Who is it for?
- Quill fits C++17 codebases where logging must not slow the hot path and where a dedicated backend thread is acceptable. It is a poor fit if you need synchronous output at the call site or a pre-C++17 compiler.
- Can I use it commercially?
- Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
- Is it still maintained?
- Yes. The repository received new commits within the last day.
- What is it written in?
- Mainly C++, according to GitHub's language statistics.
Answers come from the project's GitHub data, last synced on November 15, 2026, and from our analysis. They are not legal advice.
Star history
- odygrd/quill3,085 ★ · +53
| Repository | 2026-09-24 | 2026-11-15 |
|---|---|---|
| odygrd/quill | 3k | 3.1k |
53 Stars in the last 52 days, measured from the daily GitHub snapshot. Compare with other projects
Editorial analysis
Formatting leaves the calling thread, so output comes from a backend worker, not from the log call
Quill keeps formatting and I/O away from latency-sensitive application threads. The frontend encodes log arguments and queues them, and a dedicated backend worker processes them. The README lists this as deferred formatting: the expensive work is performed by the backend, not by the thread that called the macro.
The consequence is a design with two halves you have to start and think about separately. A log statement returns after encoding, and the line reaches the console or file later, from another thread. That is the source of the low frontend latency the project advertises, and the README points to its own benchmark methodology rather than asking you to take a number on trust. The cost is that you must start the backend, either explicitly or through the quick setup helper, and that anything which assumes a message is on disk the moment the call returns is not what this library gives you.
simple_logger() is the shortest path, and the Backend and Frontend APIs are the explicit one
For the quickest start, include SimpleSetup.h and call simple_logger. It logs to the console, or to a file if you pass a file name:
#include "quill/SimpleSetup.h"
#include "quill/LogMacros.h"
int main()
{
// log to the console
auto* logger = quill::simple_logger();
LOG_INFO(logger, "Hello from {}!", "Quill");
// log to a file
auto* logger2 = quill::simple_logger("test.log");
LOG_WARNING(logger2, "This message goes to a file");
}When you need explicit control over backend options, logger names, sinks or formatters, you use the Backend and Frontend APIs directly:
#include "quill/Backend.h"
#include "quill/Frontend.h"
#include "quill/LogMacros.h"
#include "quill/Logger.h"
#include "quill/sinks/ConsoleSink.h"
#include <string_view>
int main()
{
quill::Backend::start();
quill::Logger* logger = quill::Frontend::create_or_get_logger(
"root", quill::Frontend::create_or_get_sink<quill::ConsoleSink>("sink_id_1"));
LOG_INFO(logger, "Hello from {}!", std::string_view{"Quill"});
}The simple helper hides the logger name, which is why its sample output has no name column while the detailed setup prints root.
The macro API is the fastest path, and the function API pays for readability
Quill offers two ways to write a log call. The macro API, LOG_INFO and its siblings, is described as the lowest-latency path. A macro-free mode exposes functions such as quill::info, which read more like ordinary code but are slightly slower. The README points to a documentation page on the trade-offs.
If your goal is the smallest possible cost on the calling thread, use the macros everywhere and accept the usual macro drawbacks. If your team dislikes macros and logs outside the tightest loops, the function style is available and the cost is stated as slight. The examples directory contains both console_logging.cpp and console_logging_macro_free.cpp, plus a console_logging_module.cpp for C++ modules, so you can compare the same program written in each style before you commit your codebase to one.
Nine package managers can install it, and one entry is a version placeholder
The installation table covers vcpkg, Conan, Homebrew, Meson WrapDB, Conda, Bzlmod, xmake, nix and build2:
vcpkg install quill
conan install quill
brew install quill
meson wrap install quill
conda install -c conda-forge quill
xrepo install quill
nix-shell -p quill-logTwo other entries are not plain commands. Bzlmod uses a bazel_dep line with a version of x.y.z that you must fill in yourself, and build2 lists the package name libquill. The nix package is named quill-log, not quill. The repository itself builds with CMake and also carries BUILD.bazel, MODULE.bazel and meson.build files.
The practical catch is that each package manager has its own release schedule. The newest tag on GitHub may not yet be the one your manager serves, so confirm the version it resolved, especially across the 13.0.0 boundary.
Frontend options are fixed at compile time, while backend options change at runtime
The README splits configuration deliberately. Frontend queues and memory policy are tuned at compile time. Backend idle behaviour, CPU affinity, buffering, timestamp handling, flushing and callbacks are configured at runtime. Loggers are composed from built-in or custom sinks, with per-sink filters.
This split has a consequence for how you structure a project. Changing a queue policy means recompiling every translation unit that sees the frontend options, so it is a decision for the whole binary, not a switch to flip in a config file. Backend knobs, by contrast, can be set when the backend starts. The examples show both sides: custom_frontend_options.cpp and bounded_dropping_queue_frontend.cpp for the compile-time side, and backend_tsc_clock.cpp, backend_thread_notify.cpp and manual_backend_worker.cpp for the runtime side. The bounded dropping queue example is a hint that a full queue can be handled by dropping, so check which policy you chose.
Metrics ride the same backend, but only Prometheus ships built in
Beyond logging, Quill can publish pre-registered metrics through the same asynchronous backend. The bundled Prometheus sink handles the common metric types, and the README says custom sinks can route samples to StatsD, OpenTelemetry or other collectors. The example file is metric_publishing_prometheus.cpp.
The limit is in that wording. Prometheus is the only collector with a bundled sink, so StatsD or OpenTelemetry output means writing a sink yourself. Metrics also have to be registered before they are published, which means you cannot create a metric ad hoc at the point of use. For projects that already run the logger's backend thread, sharing it avoids another worker, but it also means a slow metrics sink and a slow log sink compete for the same backend thread.
Version 13.0.0 arrived six days after a 12.2.2 patch, so two release lines overlapped
The recent releases are v13.1.0 on 2026-10-17, v13.0.0 on 2026-08-30 and v12.2.2 on 2026-08-24. A patch release on the 12 line followed within a week by a new major version means both lines were live at the same time, and anyone on 12 should read CHANGELOG.md before moving. The last push to the repository was on 2026-10-30.
Testing is described as continuous across Linux, macOS, Windows and BSD, with sanitizers and fuzzing, and the repository holds a fuzz directory and a test directory. The README also has a Caveats section that appears in its table of contents; read it before depending on Quill in production, since the points listed there bear on exactly the behaviors discussed here. The language floor is C++17, so a project stuck on an older standard cannot use it.
Editorial conclusion
Quill fits C++17 codebases where logging must not slow the hot path and where a dedicated backend thread is acceptable. It is a poor fit if you need synchronous output at the call site or a pre-C++17 compiler. Before adopting it, read the Caveats section of the README and pin a release, because 13.0.0 was a major bump.
Frequently asked questions
What is Quill?
Quill is an asynchronous logging and metrics library for C++17 and later. It encodes log arguments on the calling thread and processes them on a dedicated backend worker.
How do I install Quill?
Use a package manager: vcpkg install quill, conan install quill, brew install quill, or conda install -c conda-forge quill. Meson, Bzlmod, xmake, nix and build2 are also supported.
How do I use Quill?
Include quill/SimpleSetup.h and quill/LogMacros.h, call quill::simple_logger(), then log with LOG_INFO(logger, "Hello from {}!", "Quill"). For more control use the Backend and Frontend APIs.
Official sources
Add this badge to your README
If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.
[](https://hysenlabs.com/projects/odygrd-quill)Star history chart for your README
[](https://hysenlabs.com/projects/odygrd-quill)Was this useful?