DEV Community

Aleix Nguyen
Aleix Nguyen

Posted on

πŸš€ Running WordPress on $0 Budget: LiteSpeed, Redis & AWS Free Tier

⚠️ This post is based on a real production setup. Some server and domain info are anonymized.



Overview

Deploying a WordPress site that serves 57,000 pageviews/week using AWS Free Tier sounds impossible β€” but it’s doable with the right stack and tuning.

This post walks through my setup using:

  • t2.micro (1GB RAM)
  • LiteSpeed Enterprise (Starter License – \$0)
  • MariaDB + Redis
  • Cloudflare (Free Plan)

Final Result:

  • ~250 concurrent users (simulated)
  • Avg TTFB: 189ms
  • Redis hit rate: 99.91%
  • RAM peak usage: 798MB
  • Zero cost infra (excluding domain)

πŸ”§ Stack

Component Tech
Server AWS EC2 t2.micro
OS Ubuntu 22.04 LTS
Web Server LiteSpeed Ent
CMS WordPress
DB MariaDB 10.5
Cache Redis + LSCache
CDN Cloudflare
HTTPS Let's Encrypt

Key Optimizations

1. Multi-layer caching

  • Redis for object cache
  • LiteSpeed Cache plugin for page-level cache
  • Cloudflare for CDN + static asset caching

2. RAM & CPU efficiency

  • Swap enabled (2GB) to extend t2.micro stability
  • Redis tuned to 256MB, allkeys-lru eviction
  • Peak memory under 800MB under 250 concurrent users

3. Deployment tricks

  • Uploaded large site zip via wget (faster than scp)
  • Adapt vHost config from OLS
  • Changed LiteSpeed WebAdmin port to avoid scans

Benchmarks

Loader.io: 250 concurrent users / 60s

  • βœ… 100% success rate
  • ⚑ Avg Response: 189ms
  • πŸ’Ύ Peak RAM: 798MB β†’ stabilized ~430MB
  • πŸ”₯ CPU: ~100% short burst, no crash

Redis hit rate:

redis-cli info stats
β†’ keyspace_hits: 1,623,661
β†’ keyspace_misses: 1,480
β†’ Hit rate: 99.91%
Enter fullscreen mode Exit fullscreen mode

Lighthouse

  • Score: 95 / 100 (desktop)
  • FCP: 0.3s
  • LCP: 0.5s

Pingdom (San Francisco)

  • Load time: ~1.78s
  • CDN: Cloudflare

Lessons Learned

  • 1GB RAM works if you optimize smart.
  • Redis + full page cache reduces load by 70–80%
  • Externalizing media (Imgur) cuts disk & CPU
  • Benchmark everything (ab, loader.io, redis-cli, curl -I)
  • Don’t rely on plugins β€” know your stack

🚫 Performance isn’t about bigger servers. It’s about smarter engineering.


Want the full guide?

πŸ‘‰ Full config & setup: GitHub Repo πŸ‘‰ Live demo: https://demo.assettolab.com dead as result of AWS Account suspension 🎁


Like it?

Give it a ❀️ and let me know your setup below. Always happy to trade war stories.


(Originally deployed from scratch by Aleix, a DevOps-leaning generalist obsessed with lean infra & real-world performance.)

Top comments (0)