The Redis vs Memcached comparison on OctoCounts shows side-by-side source line counts for redis/redis and memcached/memcached, 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 redis/redis and memcached/memcached 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-15, redis/redis contains 455,532 total lines (321,990 code) across 1,277 files, while memcached/memcached contains 56,768 total lines (41,471 code) across 139 files as of 2026-11-13. redis/redis has about 7.8x the counted code lines of memcached/memcached 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 | redis/redis | memcached/memcached |
|---|---|---|
| Files | 1,277 | 139 |
| Total lines | 455,532 | 56,768 |
| Code lines | 321,990 | 41,471 |
| Comment lines | 84,856 | 8,987 |
| Blank lines | 48,686 | 6,310 |
| Languages counted | 26 | 11 |
Top languages in redis/redis: C (69.5% of code), C Header (12.2% of code), JSON (9.7% of code). Top languages in memcached/memcached: C (74.8% of code), C Header (14.5% of code), Lua (5.4% of code). C, C Header appear in both top language lists; JSON, Module-Definition, Autoconf appear only in redis/redis's top languages; Lua, Perl, Automake appear only in memcached/memcached's top languages.
Methodology: both counts come from cached OctoCounts reports generated with tokei. redis/redis was counted at ref unstable (commit 1a9eb051aa24) on 2026-11-15; memcached/memcached was counted at ref 2d51e364799bc9698bd4b11728ea978cea12da6e (commit 2d51e364799b) on 2026-11-13. 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. redis/redis: 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. memcached/memcached: 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: redis/redis is the Redis repository — the in-memory data structure server in C, including its bundled dependencies, tests, and utilities. memcached/memcached is the Memcached repository — the in-memory key-value cache daemon in C, a more focused single-purpose codebase. Both repositories are C server trees, but Redis's includes a broader feature surface and bundled third-party code.
Redis' counted tree includes a deps directory of bundled third-party C libraries it builds against, which the per-language table reflects as additional C beyond the server code itself; Memcached's tree has no comparable bundled-dependency footprint.
The scope difference is architectural: Redis implements multiple data structures and server features in one repository, while Memcached implements one focused caching protocol — so the totals measure different breadths of responsibility.
The larger tree does not say which is faster or more suitable as a cache: throughput and latency depend on the workload, the deployed version, and the client — not on how many lines each repository contains.
Sources: redis/redis repository · memcached/memcached repository. 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-15, redis/redis contains 455,532 total lines (321,990 code) across 1,277 files, while memcached/memcached contains 56,768 total lines (41,471 code) across 139 files as of 2026-11-13. redis/redis has about 7.8x the counted code lines of memcached/memcached 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 redis/redis, memcached/memcached, or any repository.
Methodology: both counts come from cached OctoCounts reports generated with tokei. redis/redis was counted at ref unstable (commit 1a9eb051aa24) on 2026-11-15; memcached/memcached was counted at ref 2d51e364799bc9698bd4b11728ea978cea12da6e (commit 2d51e364799b) on 2026-11-13. 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.