This page compares the source lines of code (SLOC) of prometheus/prometheus and grafana/grafana 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-09-07, prometheus/prometheus contains 538,904 total lines (449,527 code) across 1,429 files, while grafana/grafana contains 4,342,761 total lines (3,743,700 code) across 20,114 files as of 2026-09-07. grafana/grafana is about 8.3x the size of prometheus/prometheus by code lines. Code size is not code quality: a larger count only means more source material, not a better or worse project.
| Metric | prometheus/prometheus | grafana/grafana |
|---|---|---|
| Files | 1,429 | 20,114 |
| Total lines | 538,904 | 4,342,761 |
| Code lines | 449,527 | 3,743,700 |
| Comment lines | 46,338 | 229,836 |
| Blank lines | 43,039 | 369,225 |
| Languages counted | 12 | 12 |
Top languages in prometheus/prometheus: Go (67.8% of code), YAML (16.2% of code), JSON (6.1% of code). Top languages in grafana/grafana: JSON (34.4% of code), Go (30.5% of code), TypeScript (16.3% of code). Go, JSON, TSX, TypeScript appear in both top language lists; YAML appears only in prometheus/prometheus's top languages; SVG appears only in grafana/grafana's top languages.
Methodology: both counts come from cached OctoCounts reports generated with tokei. prometheus/prometheus was counted at ref main (commit cba90e8518a4) on 2026-09-07; grafana/grafana was counted at ref main (commit 8a768495e10c) on 2026-09-07. See the counting methodology for ignored directories and analysis options.
Evidence and next steps:
Note: code size is not code quality. OctoCounts only reports reproducible line counts and makes no claim that either project is better.
grafana/grafana has more code: 3,743,700 code lines versus 449,527 for prometheus/prometheus, about 8.3x as much, based on cached OctoCounts reports as of 2026-09-07.
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 prometheus/prometheus, grafana/grafana, or any repository.
Methodology: both counts come from cached OctoCounts reports generated with tokei. prometheus/prometheus was counted at ref main (commit cba90e8518a4) on 2026-09-07; grafana/grafana was counted at ref main (commit 8a768495e10c) on 2026-09-07. 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.