Skip to content
SPECIFICTION
Get listed

Memcached vs Varnish Cache

Memcached

memcached.org

Varnish Cache

varnish.org

Side by side

FigureMemcachedVarnish Cache
Price fromFreeFree
Free planYesYes
Free trial——
Open source——
macOSYes—
LinuxYesYes
APIYes—
Self-hostedYesYes
Plans published11
Spec score · Caching Software7.9 (#10)7.3 (#16)
Founded20032010
PurposeMemcached is a distributed in-memory key-value cache intended to speed up dynamic web applications by reducing database load.Varnish Cache is a reverse caching proxy that serves cached responses from memory and proxies other requests to origin servers.
SupportThe project directs users to its Discord chat, documentation, and mailing list for questions, and points to Cache Forge for business support.The project points users to Discord, Stack Overflow, and LinkedIn, and says commercial support is available through Varnish Software.

Plans

Memcached

  • MemcachedFree

Memcached pricing →

Varnish Cache

  • Varnish CacheFree

Varnish Cache pricing →

In their own words

Memcached

Memcached is a free, self-hosted in-memory key-value cache for reducing database load in dynamic web applications. It keeps small chunks of arbitrary data, such as strings, objects, and results from database calls, API calls, or page rendering. Clients use key-based hashing to choose a server, while servers operate independently without synchronization or replication. Items can expire after a specified time, and the default eviction policy is least recently used (LRU). The project describes Memcached as a developer tool, not code acceleration software or database middleware. Its API is available for most popular languages, and downloads include a source tarball and installation instructions with package prerequisites for Debian/Ubuntu and Red Hat/CentOS. TLS authentication and encryption are supported in version 1.5.13 and later when built with TLS and used with a TLS-capable client. Optional extstore moves values to external storage while keeping keys and the hash table in memory; it needs version 1.6.0 or newer. The project began in 2003. It is free and self-hosted, with no hosted plan or price listed.

Visit memcached.org

Varnish Cache

Varnish Cache is a reverse caching proxy for Linux and self-hosted deployments. It serves cached responses from memory and sends other requests to origin servers. Its caching policy is defined in Varnish Configuration Language (VCL), which compiles to native code. Cached objects follow standard HTTP cache headers and leave the cache when they expire. Varnish supports TLS termination within the process and TLS connections to dynamic origin backends. It includes varnishlog for structured logging and varnishstat for metrics, and offers official container images and a Kubernetes Helm chart. Installation guidance covers Debian, Ubuntu, Red Hat Enterprise Linux, and compatible distributions. Varnish modules add functions callable from VCL. Its security guide describes controls at the command-line, CLI, VCL, and HTTP request levels. The free plan costs nothing. One limit to account for: Varnish avoids caching data when it cannot determine that doing so is safe, and applications may need configuration changes to reach a high cache hit rate.

Visit varnish.org