Skip to content

High-performance full-page caching for WordPress using Redis, ValKey, KeyDB, or Dragonfly.

License

Notifications You must be signed in to change notification settings

MilliPress/MilliCache

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

107 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MilliCache

CI e2e-Tests

High-performance full-page caching for WordPress using Redis, ValKey, KeyDB, or Dragonfly.

MilliCache stores complete HTML pages in memory and serves them in milliseconds — without loading WordPress. Combined with intelligent cache flags and flexible rules, it's designed for scaling sites that need both speed and control.

Key Features

  • Lightning Fast — In-memory caching with blazing fast response times
  • Cache Flags — Tag pages for precise, targeted cache invalidation
  • Flexible Rules — Control caching behavior with condition-based rules
  • Multisite Native — Per-site isolation, network-wide management
  • Built to Scale — Multiple web servers can share a single Redis instance
  • WP-CLI Integration — Full command-line cache management
  • Multiple Backends — Redis, ValKey, KeyDB, or Dragonfly

Learn more on millipress.com, where you also find the full documentation.

Quick Start

  1. Install via ZIP download or Composer:

    composer require millipress/millicache
  2. Activate the plugin in WordPress admin

  3. Enable caching in wp-config.php:

    define( 'WP_CACHE', true );
    
    // Optional: Configure Redis connection
    define( 'MC_STORAGE_HOST', '127.0.0.1' );
    define( 'MC_STORAGE_PORT', 6379 );
  4. Verify in Settings UI, Browser Developer Tools, or with WP-CLI:

    wp millicache test
    wp millicache status

Documentation

Full documentation is available on millipress.com/docs/millicache:

Section Description
Getting Started Introduction and installation
Configuration Settings and constants reference
Cache Flags Targeted cache invalidation
Rules Condition-based caching control
Usage How caching works, clearing, multisite
WP-CLI Command-line reference
Developers Architecture, hooks, API
Storage Backends Redis, ValKey, KeyDB, Dragonfly
Troubleshooting Common issues and FAQ

Requirements

Testing

MilliCache uses PHPUnit, PHPStan, and Playwright for testing. To run tests locally:

# Start test environment (requires Docker + Node.js)
npm install
npm run env:start

# Run e2e tests
npm run env:e2e

# Stop environment
npm run env:stop

Test WordPress available at http://localhost:8888 (login: admin / password)

Useful Commands

npm run env:cli wp millicache stats    # Run WP-CLI commands
npm run env:redis-cli                  # Open Redis CLI
npm run env:reset                      # Reset environment

Credits

MilliCache was initially inspired by:

License

GPLv2 or later

About

High-performance full-page caching for WordPress using Redis, ValKey, KeyDB, or Dragonfly.

Topics

Resources

License

Stars

Watchers

Forks

Contributors 4

  •  
  •  
  •  
  •