# magento/magento2 SLOC report

> magento/magento2: 2,154,474 code lines at commit 16f4fa211bfd, counted with tokei-14.0.0 on 2026-10-22. Saved result 9f64c78dbddf716786c3e303593cd67b81c3595684933358e880eeb6645686f6.

magento/magento2 has 2,154,474 source lines of code out of 3,425,154 total lines across 32,400 files, counted from the 2.4-develop ref at commit 16f4fa211bfd by the OctoCounts tokei engine on 2026-10-22. The report is cached by commit, tokei version, and analysis options, so recounting the same revision returns exactly these numbers.

OctoCounts produced this report by resolving magento/magento2 to commit 16f4fa211bfd, downloading the repository source archive, and counting every source file 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, so counting the same revision again reproduces exactly these numbers.

## Repository size insights

This is a very large codebase by counted code lines. Code represents 62.9% of all lines, comments represent 27.1%, and the repository averages 66 code lines per file. PHP accounts for 67.0% of counted code.

| Language | Files | Lines | Code | Comments | Blanks |
| --- | ---: | ---: | ---: | ---: | ---: |
| PHP | 19,697 | 2,471,207 | 1,442,973 | 768,730 | 259,504 |
| XML | 9,088 | 426,530 | 334,677 | 73,284 | 18,569 |
| JavaScript | 1,294 | 335,013 | 256,949 | 45,964 | 32,100 |
| LESS | 432 | 78,499 | 59,093 | 7,080 | 12,326 |
| CSS | 90 | 28,545 | 27,580 | 408 | 557 |
| JSON | 326 | 21,492 | 21,492 | 0 | 0 |
| HTML | 372 | 12,569 | 8,350 | 3,704 | 515 |
| TypeScript | 1 | 3,252 | 3,252 | 0 | 0 |
| SVG | 20 | 108 | 108 | 0 | 0 |
| Markdown | 429 | 14,693 | 0 | 12,154 | 2,539 |
| Plain Text | 651 | 33,246 | 0 | 18,350 | 14,896 |

Top language (PHP 67.0%). Generated at 2026-10-22T06:14:36.724280711Z. Canonical report: https://octocounts.com/github/magento/magento2/commit/16f4fa211bfdecda84c3e7d475f1514780b170c6?reportId=9f64c78dbddf716786c3e303593cd67b81c3595684933358e880eeb6645686f6&analysis=%7B%22profile%22%3A%22default%22%2C%22ignoredDirs%22%3A%5B%5D%2C%22includeDocs%22%3Afalse%2C%22includeTests%22%3Afalse%2C%22ignoredLanguages%22%3A%5B%5D%2C%22includeGenerated%22%3Afalse%7D

## Reproduce this report

[Reproduce this exact report and configuration](https://octocounts.com/github/magento/magento2/commit/16f4fa211bfdecda84c3e7d475f1514780b170c6?reportId=9f64c78dbddf716786c3e303593cd67b81c3595684933358e880eeb6645686f6&analysis=%7B%22profile%22%3A%22default%22%2C%22ignoredDirs%22%3A%5B%5D%2C%22includeDocs%22%3Afalse%2C%22includeTests%22%3Afalse%2C%22ignoredLanguages%22%3A%5B%5D%2C%22includeGenerated%22%3Afalse%7D).

## Report FAQ

### How many lines of code does magento/magento2 have?

magento/magento2 has 3,425,154 total lines, including 2,154,474 code lines, 929,674 comment lines, and 341,006 blank lines.

### How was the magento/magento2 line count measured?

OctoCounts resolved the public GitHub repository to commit 16f4fa211bfd, downloaded the source archive, counted it with tokei, and cached the report by commit, tokei version, and analysis options.

### What commit was counted for magento/magento2?

This OctoCounts report was generated from 2.4-develop at commit 16f4fa211bfd on 2026-10-22T06:14:36.724280711Z.

## Similar repository reports

- [Dolibarr/dolibarr](https://octocounts.com/github/Dolibarr/dolibarr) — PHP, 1,510,195 code lines
- [symfony/symfony](https://octocounts.com/github/symfony/symfony) — PHP, 1,305,566 code lines
- [moodle/moodle](https://octocounts.com/github/moodle/moodle) — PHP, 4,116,520 code lines
- [ccxt/ccxt](https://octocounts.com/github/ccxt/ccxt) — PHP, 4,333,902 code lines
- [WordPress/WordPress](https://octocounts.com/github/WordPress/WordPress) — PHP, 795,478 code lines
- [SuiteCRM/SuiteCRM](https://octocounts.com/github/SuiteCRM/SuiteCRM) — PHP, 727,564 code lines

## Related OctoCounts pages

- [Recently analyzed repositories](https://octocounts.com/recent)
- [Popular SLOC reports](https://octocounts.com/popular)
- [Trending GitHub repositories](https://octocounts.com/trending)
- [Hall of Monoliths](https://octocounts.com/hall-of-monoliths)
- [Laravel vs Django](https://octocounts.com/compare/laravel-vs-django)
- [Django vs Ruby on Rails](https://octocounts.com/compare/django-vs-rails)
- [GitHub SLOC counter guide](https://octocounts.com/docs/github-sloc-counter)
- [Counting methodology](https://octocounts.com/docs/methodology)
- [SLOC and code metrics glossary](https://octocounts.com/docs/glossary)
- [Original research: how filtering changes SLOC counts](https://octocounts.com/research)
- [OctoCounts API docs](https://octocounts.com/docs/api)
