SagerNet/sing-box has 170,455 source lines of code out of 193,094 total lines across 1,219 files, counted from the testing ref at commit dfb80349bf57 by the OctoCounts tokei engine on 2026-10-14. The report is cached by commit, tokei version, and analysis options, so recounting the same revision returns exactly these numbers.
As of 2026-10-14 (commit dfb80349bf57), SagerNet/sing-box contains 193,094 total lines: 170,455 code, 4,488 comments, 18,151 blank, across 1,219 files in 17 languages (top: Go 97.2%). Custom configuration (tests excluded, docs excluded, generated excluded). Counted with tokei via OctoCounts.
OctoCounts produced this report by resolving SagerNet/sing-box to commit dfb80349bf57, 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.
This is a large codebase by counted code lines. Code represents 88.3% of all lines, comments represent 2.3%, and the repository averages 140 code lines per file. Go accounts for 97.2% of counted code.
| Language | Files | Lines | Code | Comments | Blanks |
|---|---|---|---|---|---|
| Go | 1182 | 186237 | 165731 | 3341 | 17165 |
| BASH | 1 | 1580 | 1289 | 41 | 250 |
| Objective-C | 4 | 1292 | 1201 | 3 | 88 |
| Protocol Buffers | 5 | 1120 | 949 | 3 | 168 |
| YAML | 1 | 327 | 316 | 2 | 9 |
| Makefile | 1 | 296 | 220 | 3 | 73 |
| Shell | 8 | 228 | 166 | 8 | 54 |
| Zsh | 1 | 212 | 146 | 36 | 30 |
| Fish | 1 | 235 | 140 | 49 | 46 |
| C Header | 4 | 141 | 116 | 6 | 19 |
| C | 2 | 104 | 91 | 0 | 13 |
| JSON | 1 | 41 | 41 | 0 | 0 |
Top language (Go 97.2%). Generated at .
SagerNet/sing-box has 193,094 total lines, including 170,455 code lines, 4,488 comment lines, and 18,151 blank lines.
OctoCounts resolved the public GitHub repository to commit dfb80349bf57, 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 testing at commit dfb80349bf57 on 2026-10-14T11:03:05.608235401+00:00.
Other public repositories with an OctoCounts report, ranked by top language and code size similarity:
Play the growth animation for SagerNet/sing-box on this page — 170,455 code lines across 12 languages, counted by tokei.