My own CodeIgniter 4 Email Queue Addin

post Main Image

A lean, database-backed email queue addin for CodeIgniter 4 that simplifies deferred sending via cron—no workers, no external services, just clean CLI control.

GitHub repo is here.

I built a minimal email queue addin for CodeIgniter 4 to streamline deferred email sending via cron. It installs via Composer, stores jobs in a database table, and is ideal for transactional or batch email flows. Open-source, clean, and built for quick integration.

If you’ve ever wanted to queue emails in CI4 without setting up Redis, workers, or a full job system, this addin might be what you need. It creates an email_queue table via migration and lets you insert jobs directly from your controllers. To dispatch emails, run php spark email:sendqueue—a CLI command that processes unsent entries and retries failed ones. It’s designed for cron-based execution, so you can control frequency without persistent listeners.

Compared to CodeIgniter’s official queue library, which supports multiple backends and complex job orchestration, this addin is purpose-built for email: simple, focused, and easy to drop into any CI4 project. It’s ideal for developers who want deferred sending without the overhead. I’m planning cleanup tools and templated email support next, and I’d love feedback from anyone who gives it a try.