mongodb/mongo has 7,655,692 source lines of code out of 10,631,169 total lines across 39,706 files, counted with tokei from the master ref at commit 872f36026cf9 on November 16, 2026. Tests, docs and generated files are excluded under OctoCounts' canonical public options.
mongodb/mongo: 7,655,692 code lines at commit 872f36026cf9, counted with tokei-15.0.0 on 2026-11-16. Saved result f54134b0b88f5899412256b9725802c7336b574c90ee47ffc0a43523e7c0b4a0.
OctoCounts produced this report by resolving mongodb/mongo to commit 872f36026cf9, downloading the repository source archive, and counting files selected by the effective rules with tokei, the open-source line counter written in Rust. The table below breaks the count down by programming language into files, total lines, code lines, comment lines, and blank lines, so the figures can be compared across languages and projects. Results are cached by commit, tokei version, and analysis options; an exact reproduction needs the same commit, engine version, and effective counting rules.
This is a very large codebase by counted code lines. Code represents 72.0% of all lines, comments represent 16.0%, and the repository averages 193 code lines per file. C++ accounts for 34.1% of counted code.
| Language | Files | Lines | Code | Comments | Blanks |
|---|---|---|---|---|---|
| C++ | 7981 | 3439365 | 2610987 | 342402 | 485976 |
| C++ Header | 9831 | 2183419 | 1623187 | 293946 | 266286 |
| C Header | 7045 | 1879045 | 1168183 | 484357 | 226505 |
| JavaScript | 8390 | 1419255 | 1067494 | 201543 | 150218 |
| C | 871 | 789944 | 586381 | 135467 | 68096 |
| Python | 844 | 224782 | 175783 | 16178 | 32821 |
| Autoconf | 24 | 140999 | 137041 | 2737 | 1221 |
| Bazel | 1243 | 117536 | 103276 | 4257 | 10003 |
| YAML | 1662 | 85083 | 70139 | 10121 | 4823 |
| Bitbake | 16 | 37247 | 37104 | 14 | 129 |
| Shell | 392 | 24979 | 17583 | 3719 | 3677 |
| JSON | 185 | 16605 | 16604 | 0 | 1 |
| Visual Studio Project | 8 | 6042 | 6042 | 0 | 0 |
| GNU Style Assembly | 82 | 10146 | 4913 | 4099 | 1134 |
| TOML | 5 | 5436 | 4785 | 132 | 519 |
| Perl | 12 | 4886 | 3758 | 642 | 486 |
| RPM Specfile | 11 | 3225 | 2498 | 44 | 683 |
| Makefile | 23 | 3733 | 2456 | 547 | 730 |
| HTML | 4 | 2649 | 2397 | 26 | 226 |
| SWIG | 2 | 2338 | 1718 | 301 | 319 |
| CMake | 40 | 2262 | 1546 | 442 | 274 |
| Batch | 19 | 1693 | 1495 | 21 | 177 |
| Templ | 7 | 1577 | 1459 | 0 | 118 |
| Assembly | 18 | 2572 | 1442 | 825 | 305 |
| BASH | 6 | 1803 | 1257 | 319 | 227 |
| TypeScript | 34 | 3640 | 910 | 2263 | 467 |
| Protocol Buffers | 14 | 2298 | 620 | 1400 | 278 |
| PowerShell | 8 | 724 | 497 | 138 | 89 |
| ReStructuredText | 7 | 597 | 464 | 0 | 133 |
| Snakemake | 6 | 633 | 450 | 76 | 107 |
| CSS | 2 | 577 | 447 | 30 | 100 |
| Jupyter Notebooks | 3 | 542 | 403 | 43 | 96 |
| Dockerfile | 17 | 654 | 358 | 216 | 80 |
| Forge Config | 15 | 410 | 338 | 11 | 61 |
| D | 2 | 306 | 261 | 22 | 23 |
| TCL | 7 | 365 | 261 | 56 | 48 |
| Java | 1 | 268 | 192 | 46 | 30 |
| Pan | 1 | 172 | 131 | 23 | 18 |
| Rust | 7 | 187 | 128 | 29 | 30 |
| Scheme | 1 | 155 | 121 | 8 | 26 |
| LD Script | 6 | 85 | 85 | 0 | 0 |
| Visual Studio Solution | 2 | 80 | 80 | 0 | 0 |
| Lua | 2 | 86 | 69 | 3 | 14 |
| GDB Script | 2 | 67 | 51 | 12 | 4 |
| Prolog | 2 | 69 | 51 | 0 | 18 |
| Monkey C | 1 | 58 | 41 | 12 | 5 |
| Module-Definition | 3 | 40 | 38 | 0 | 2 |
| jq | 4 | 44 | 38 | 0 | 6 |
| CUDA | 1 | 72 | 36 | 21 | 15 |
| Swift | 1 | 36 | 27 | 7 | 2 |
| SVG | 1 | 26 | 26 | 0 | 0 |
| XML | 2 | 17 | 15 | 1 | 1 |
| R | 1 | 38 | 12 | 18 | 8 |
| INI | 6 | 6 | 6 | 0 | 0 |
| ReScript | 2 | 4 | 4 | 0 | 0 |
| Objective-C | 2 | 14 | 2 | 12 | 0 |
| Objective-C++ | 2 | 14 | 2 | 12 | 0 |
| Markdown | 328 | 95914 | 0 | 84033 | 11881 |
| Plain Text | 492 | 116350 | 0 | 111673 | 4677 |
Top language: C++ 34.1%. Generated on .
mongodb/mongo: 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.
Saved reports remain subject to cache cleanup and replacement. Export the JSON or text for durable citation; live repository URLs can change.
mongodb/mongo has 7,655,692 lines of code, plus 1,702,304 comment lines and 1,273,173 blank lines, for 10,631,169 total lines at commit 872f36026cf9 on November 16, 2026. Tests, docs and generated files are excluded under OctoCounts' canonical public options.
OctoCounts resolved the public GitHub repository to commit 872f36026cf9, downloaded the source archive, counted it with tokei, and cached the report by commit, tokei version, and analysis options.
This OctoCounts report was generated from master at commit 872f36026cf9 on November 16, 2026.
Other public repositories with an OctoCounts report, ranked by top language and code size similarity:
Play the growth animation for mongodb/mongo on this page — 7,655,692 code lines across 59 languages, counted by tokei.