The Swift vs Kotlin comparison on OctoCounts shows side-by-side source line counts for swiftlang/swift and JetBrains/kotlin, 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 swiftlang/swift and JetBrains/kotlin 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-16, swiftlang/swift contains 3,336,604 total lines (2,299,938 code) across 14,877 files, while JetBrains/kotlin contains 5,814,652 total lines (2,488,745 code) across 86,754 files as of 2026-11-16. swiftlang/swift and JetBrains/kotlin are similar in size 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 | swiftlang/swift | JetBrains/kotlin |
|---|---|---|
| Files | 14,877 | 86,754 |
| Total lines | 3,336,604 | 5,814,652 |
| Code lines | 2,299,938 | 2,488,745 |
| Comment lines | 695,662 | 2,554,023 |
| Blank lines | 341,004 | 771,884 |
| Languages counted | 33 | 37 |
Top languages in swiftlang/swift: C++ (39.2% of code), JSON (22.7% of code), Swift (18.1% of code). Top languages in JetBrains/kotlin: Kotlin (76.1% of code), Java (13.3% of code), JSON (2.6% of code). C++, JSON, Swift appear in both top language lists; C Header, Module-Definition appear only in swiftlang/swift's top languages; Kotlin, Java appear only in JetBrains/kotlin's top languages.
Methodology: both counts come from cached OctoCounts reports generated with tokei. swiftlang/swift was counted at ref main (commit d349aa60316b) on 2026-11-16; JetBrains/kotlin was counted at ref master (commit a8d6b6fe20b8) on 2026-11-16. 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. swiftlang/swift: 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. JetBrains/kotlin: 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: swiftlang/swift is the Swift repository — the compiler, standard library, and toolchain for the Swift programming language. JetBrains/kotlin is the Kotlin repository — the compiler and core language infrastructure for Kotlin. Both are language-toolchain repositories rather than libraries or applications, counted with the rules shown above, which makes this one of the more like-for-like comparisons on this site.
The per-language tables reflect each project's self-hosting trajectory: Swift's counted tree is a mix of C++ compiler code and an increasingly large Swift standard library, while Kotlin's counted tree is predominantly Kotlin with the runtime boundaries still maintained in other languages.
Language repository size does not measure language capability, compile speed, or runtime performance — those are properties of the shipped toolchain and the programs it compiles, not of the source tree's line count.
Sources: swiftlang/swift repository (compiler and standard library) · JetBrains/kotlin repository (compiler and core infrastructure). 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-16, swiftlang/swift contains 3,336,604 total lines (2,299,938 code) across 14,877 files, while JetBrains/kotlin contains 5,814,652 total lines (2,488,745 code) across 86,754 files as of 2026-11-16. swiftlang/swift and JetBrains/kotlin are similar in size 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 swiftlang/swift, JetBrains/kotlin, or any repository.
Methodology: both counts come from cached OctoCounts reports generated with tokei. swiftlang/swift was counted at ref main (commit d349aa60316b) on 2026-11-16; JetBrains/kotlin was counted at ref master (commit a8d6b6fe20b8) on 2026-11-16. 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.