The Zap vs Logrus comparison on OctoCounts shows side-by-side source line counts for uber-go/zap and sirupsen/logrus, counted under the rules and on the dates stated below: files, total lines, code lines, comment lines, blank lines, and per-language totals, pinned to the exact commits listed below.
This page compares the source lines of code (SLOC) of uber-go/zap and sirupsen/logrus using cached OctoCounts reports. Code size is not code quality: a larger count only means more source material, not a better or worse project.
As of 2026-11-09, uber-go/zap contains 25,419 total lines (16,537 code) across 151 files, while sirupsen/logrus contains 9,618 total lines (6,684 code) across 56 files as of 2026-10-31. uber-go/zap has about 2.5x the counted code lines of sirupsen/logrus under the same engine and counting rules. Code size is not code quality: a larger count only means more source material, not a better or worse project.
| Metric | uber-go/zap | sirupsen/logrus |
|---|---|---|
| Files | 151 | 56 |
| Total lines | 25,419 | 9,618 |
| Code lines | 16,537 | 6,684 |
| Comment lines | 6,085 | 1,435 |
| Blank lines | 2,797 | 1,499 |
| Languages counted | 5 | 3 |
Top languages in uber-go/zap: Go (99.4% of code), Makefile (0.3% of code), YAML (0.2% of code). Top languages in sirupsen/logrus: Go (99.9% of code), YAML (0.1% of code), Markdown (0.0% of code). Go, YAML, Markdown appear in both top language lists; Makefile, Shell appear only in uber-go/zap's top languages.
Methodology: both counts come from cached OctoCounts reports generated with tokei. uber-go/zap was counted at ref bbd4ecbd8760678fdbac94c93d9aca8069c83b2f (commit bbd4ecbd8760) on 2026-11-09; sirupsen/logrus was counted at ref master (commit 6ef0748d1177) on 2026-10-31. See the counting methodology for ignored directories and analysis options.
Both reports use the same engine and effective counting rules. Repository declarations, when enabled, are specific to each repository. uber-go/zap: tokei-15.0.0, policy directories-v1; docs excluded, tests excluded, generated excluded. Excluded directory names: .cache, .generated, .git, .next, __tests__, build, dist, doc, docs, documentation, fixtures, gen, generated, node_modules, target, test, tests, vendor. Ignored languages: none. Repository declarations: off. Exclusions are rule-based; they do not prove that every test, document or generated file was removed. sirupsen/logrus: tokei-15.0.0, policy directories-v1; docs excluded, tests excluded, generated excluded. Excluded directory names: .cache, .generated, .git, .next, __tests__, build, dist, doc, docs, documentation, fixtures, gen, generated, node_modules, target, test, tests, vendor. Ignored languages: none. Repository declarations: off. Exclusions are rule-based; they do not prove that every test, document or generated file was removed.
Background observations recorded on 2026-09-16; language descriptions here are historical context, not claims about the current filtered shares. Use this page's measured language breakdown for current counts. Repository layout before counting filters: uber-go/zap is the Zap repository — Uber's structured logging library for Go — while sirupsen/logrus is the Logrus repository, the older Go logging library whose API many other Go packages adopted. Both are single-purpose Go libraries rather than frameworks, counted with the rules shown above, making this one of the more like-for-like comparisons on this site.
Both repositories are Go codebases, as the per-language tables show; the comparison on the page is between two implementations of the same library role rather than across languages or architectures.
Library size does not measure logging performance or suitability: allocation behavior, API shape, and maintenance status are properties not visible in source-line counts. Logrus is widely known to be in maintenance mode, which no line count will show.
Sources: uber-go/zap repository (structured logging library) · sirupsen/logrus repository. Statements verified 2026-09-16.
Evidence and next steps:
Saved reports remain subject to cache cleanup and replacement. Export their JSON for durable citation; live report URLs can change.
Note: code size is not code quality. OctoCounts only reports reproducible line counts and makes no claim that either project is better.
As of 2026-11-09, uber-go/zap contains 25,419 total lines (16,537 code) across 151 files, while sirupsen/logrus contains 9,618 total lines (6,684 code) across 56 files as of 2026-10-31. uber-go/zap has about 2.5x the counted code lines of sirupsen/logrus under the same engine and counting rules. Code size is not code quality: a larger count only means more source material, not a better or worse project.
Not necessarily. SLOC measures size, not complexity, quality, or maintainability. A larger codebase can mean more features, more generated or vendored code, more verbose language idioms, or more tests — none of which imply the code is harder to work with. Use SLOC to gauge the scale of what you'd be reading or maintaining, not as a quality signal for uber-go/zap, sirupsen/logrus, or any repository.
Methodology: both counts come from cached OctoCounts reports generated with tokei. uber-go/zap was counted at ref bbd4ecbd8760678fdbac94c93d9aca8069c83b2f (commit bbd4ecbd8760) on 2026-11-09; sirupsen/logrus was counted at ref master (commit 6ef0748d1177) on 2026-10-31. See the counting methodology for ignored directories and analysis options.
Yes. This page shows the default branch for each repository. Use the interactive comparison tool to pick any public GitHub repository, branch, tag, or commit SHA for both sides and get a fresh side-by-side report.