# rxi/log.c

A simple logging library implemented in C99

Repository: https://github.com/rxi/log.c
Canonical: https://ross.abutalabs.com/products/logc
Language: C
License: MIT
License Family: permissive
Last push: 2024-07-21T08:58:43+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 3461, "days_push": 773, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 3548, forks 698 (observed 2026-08-28T04:08:09.455440+00:00)

## What it is
A simple logging library for C99 that provides printf-style logging macros across six severity levels. It is a drop-in two-file library supporting quiet mode, log levels, file and callback outputs, thread locking, and optional ANSI colors.

## Use cases
- add logging to a C project
- log to stderr and files in C
- thread-safe logging in C
- simple printf-style log macros
- colored log output in a terminal

## When to choose
- you need a tiny, dependency-free logging solution in C
- you want to drop two files into an existing project
- you need multiple log outputs (stderr, files, callbacks) with levels

## When to avoid
- you need structured/JSON logging or log rotation
- you want async or high-performance logging at scale
- you are not writing C

## Facets
- artifact type: library
- maturity: stable
- function: logging
- domain: developer-tools
- platform: c, cross-platform, embedded
- tags: c99, single-file, header-drop-in, thread-safe, ansi-colors, command-line

## Member repositories
- rxi/log.c (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:08:09.455440+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T18:34:23.214983+00:00, confidence not recorded.
  - readme: https://github.com/rxi/log.c (fetched 2026-08-28T04:08:09.455440+00:00, sha 39addcd5f22b)
- Data as of 2026-08-30T08:39:29.467469+00:00.
