env_logger

Environment-variable-configured logging backend for Rust's log crate

Library
Cargo
v0.11.11
1,063stars
MIT OR Apache-2.0

Repository Health

Pre-computed score based on development activity, maintenance, community, maturity, and trend momentum.How we score it →
78/100Good
Development Activity80
Maintenance68
Community76
Maturity60
Momentum28

Technical Analysis

AI-assessed by reading the actual repository — architecture, code quality, innovation, and documentation.How we score it →
76/100Good
Architecture78
Code Quality80
Innovation62
Learning Curve85

env_logger is the de-facto default backend for Rust’s log facade, letting you control log levels and per-module filtering entirely through the RUST_LOG environment variable rather than code changes or config files. It writes human-readable, optionally colored output to stderr (or stdout) and supports fine-grained filters like RUST_LOG=my_crate=debug,other_crate=warn.

The project is a Cargo workspace that also publishes env_filter as a separate crate — the underlying filter-parsing engine env_logger builds on — so other logging backends can reuse the same RUST_LOG-style filter syntax without depending on env_logger’s full formatting/writer stack.

What You Get

  • A ready-to-use log::Log implementation activated with a single env_logger::init() call
  • RUST_LOG-style filter syntax supporting per-module and per-level granularity (e.g. my_crate=debug,hyper=warn)
  • Configurable output target (stderr/stdout), timestamp formats, and color support via a Builder API
  • A separate env_filter crate exposing just the filter-string parsing logic for reuse by other logging backends
  • Custom formatter support for fully overriding how each log record is rendered

Common Use Cases

  • Adding basic, zero-config logging output to a CLI tool or service with a single env_logger::init() call
  • Selectively enabling debug-level logs for one dependency while keeping others at warn/error during troubleshooting
  • Building a custom logging backend that wants to reuse env_logger’s RUST_LOG filter parser (env_filter) without its formatter/writer
  • Testing binaries where log verbosity needs to be toggled per test run via environment variables rather than recompiling

Under The Hood

Architecture - the repo is a Cargo workspace with the top-level env_logger package as the umbrella crate (src/lib.rs, src/logger.rs, plus src/fmt for output formatting and src/writer for the stderr/stdout output target) and crates/env_filter as a workspace member providing the standalone RUST_LOG filter-parsing engine that env_logger depends on internally, letting other logging backends adopt the same filter syntax independently. Tech Stack - pure Rust, built on the log crate’s facade pattern (implementing its Log trait), with optional humantime/color-output dependencies gated behind Cargo features, and a workspace-wide Clippy lint configuration ([workspace.lints.clippy]) enforcing a large, curated set of lint rules across both crates. Code Quality - the tests/ directory targets specific historical correctness issues (log-in-log.rs, log_tls_dtors.rs, init-twice-retains-filter.rs, regexp_filter.rs), showing regression coverage for real bugs rather than only happy-path tests, and the workspace enforces a strict shared lint policy (unreachable_pub, unsafe_op_in_unsafe_fn, etc.) across all member crates. API Design - the common path is a single env_logger::init() call with zero required configuration, while a Builder escape hatch exposes format, filter, and target customization for more advanced setups — keeping the learning curve close to zero for the default case while still supporting deep customization.

Used by 15 apps in this directory

C++
68%
Apache 2.0

ClickHouse

Databases · Analytics · Data Engineering

49,673

Open-source column-oriented database that delivers real-time analytical queries on petabyte-scale data with millisecond latency.

View details
95
Repo Health
90
Technical
68
Dependency
Built with
C++68%
Python13%
Updated today
Go
32%
Apache 2.0

CubeSandbox

Developer Tools · Security · AI Agents

11,816

Instant, concurrent, hardware-isolated MicroVM sandboxes for AI agents — E2B-API compatible, sub-60ms cold starts, and a built-in zero-trust egress proxy, all self-hostable at scale.

View details
83
Repo Health
88
Technical
63
Dependency
Built with
Go32%
Rust28%
C23%
Updated yesterday
Rust
58%
MIT

Handy

Productivity

31,111

Free, offline, open-source speech-to-text that pastes directly into any app on Windows, macOS, and Linux.

View details
86
Repo Health
78
Technical
73
Dependency
Built with
Rust58%
TypeScript30%
Updated 2 days ago
TypeScript
71%
Other

highlight.io

Developer Tools · Analytics · Monitoring

9,372

Open-source full-stack monitoring that unifies session replay, error tracking, logging, and distributed tracing so you can stop context-switching between tools.

View details
69
Repo Health
78
Technical
65
Dependency
Built with
TypeScript71%
Go16%
Updated 2 weeks ago
TypeScript
67%
MIT

Hoppscotch

Developer Tools

80,226

A lightweight, offline-capable API development ecosystem for testing HTTP, GraphQL, WebSocket, MQTT, and SSE endpoints across web, desktop, and CLI.

View details
92
Repo Health
83
Technical
66
Dependency
Built with
TypeScript67%
Vue25%
Updated yesterday
TypeScript
51%
Other

Jan

AI Assistants

44,366

Run LLMs 100% locally with full privacy, or connect to cloud AI — your machine, your data, your control.

View details
89
Repo Health
81
Technical
65
Dependency
Built with
TypeScript51%
Rust46%
Updated 3 days ago
Rust
46%
MIT

Meetily

Productivity · AI Assistants

30,423

Privacy-first AI meeting assistant that transcribes and summarizes your meetings entirely on your local machine — no cloud, no data leakage.

View details
61
Repo Health
72
Technical
71
Dependency
Built with
Rust46%
TypeScript30%
Updated yesterday
C++
66%
Other

Memgraph

Databases · AI Development

4,392

High-performance in-memory graph database for AI context and real-time analytics

View details
90
Repo Health
79
Technical
69
Dependency
Built with
C++66%
Python18%
Updated yesterday
Rust
43%
BSD 3

MicroBin

File Storage

4,544

A self-contained, encrypted paste bin and file-sharing app in Rust with animal-name URLs, burn-after-read, and one-command Docker deployment.

View details
55
Repo Health
67
Technical
71
Dependency
Built with
Rust43%
HTML28%
JavaScript20%
Updated 2 months ago

Join founders buildingwith open source

Opinionated takes, migration guides, cost-saving tips, and insights from the open source ecosystem.

Subscribe on Substack
Join 750+ subscribers

Search