DEV3 AI Abandoned Cart & Win-back Emails for WooCommerce

WooCommerce plugin that captures carts on the classic and block checkout with GDPR consent, runs email and SMS recovery and win-back sequences with unique coupons, and tunes each send to the shopper's local hour. Google Gemini API copy waits for human review.

by DEV3 TechnologiesVerified Author(0) 0 downloads 0 viewsUpdated 29 Oct 2026
1 / 8

WooCommerce plugin that captures carts on the classic and block checkout with GDPR consent, runs email and SMS recovery and win-back sequences with unique coupons, and tunes each send to the shopper's local hour. Google Gemini API copy waits for human review. Free download: sign in and click Download ZIP. Add your own Google AI Studio (Gemini) API key to switch on the AI features; the documentation says which features work without one.

How it works

We built DEV3 AI Abandoned Cart & Win-back Emails as a WooCommerce plugin in PHP with a React admin and a small dependency-free storefront script. A WP-Cron sweep every five minutes drives everything: it detects abandonment, enrols lapsed customers into win-back, prepares AI drafts ahead of their send time, sends what is due and closes finished carts.

Key design decisions

  • Capture on both checkouts. The classic checkout is captured from debounced field changes; the block checkout is captured server-side from the Store API hook woocommerce_store_api_cart_update_customer_from_request, with the same script adding consent and the browser's timezone offset. The public capture route is same-origin, rate limited and returns no personal data, so full-page caching keeps working.
  • Three consent modes. Notice (default), opt-in (nothing personal is stored until the box is ticked; unticking deletes the stored cart) and none. SMS always needs its own opt-in. Every email carries a signed one-click unsubscribe link and List-Unsubscribe headers; unsubscribed addresses are kept only as hashes.
  • Sequences as a small state machine. A cart records how many steps were sent or skipped; each step is a scheduled message row. Purchases, unsubscribes and the admin's Stop action cancel what is pending, steps that cannot be sent (unapproved template, no SMS consent) are skipped with a logged reason, and an atomic option lock stops two sweeps overlapping.
  • Forward-only send-time tuning. A send can only move later, never earlier, by at most a configurable number of hours, to the hour that scores best for that shopper (their own order hours, then their open and click hours, then store-wide clicks) outside quiet hours in the shopper's own timezone. The first reminder moves at most one hour.
  • AI drafts behind a review gate. The Google Gemini API rewrites a template per cart from the first name and product names only. Drafts wait in a review queue with a word diff against the template. If nobody reviews one before its send time, the approved template copy goes out instead, or the message is held for a set number of hours. Only templates with auto-approve switched on send AI copy without review.
  • Coupons and restore links. Each step can mint a unique WooCommerce coupon (single use, individual use, locked to the shopper's email). The recovery link carries a cart token, the message id and an HMAC, restores items, quantities and variations, applies the coupon and pre-fills the checkout.

Architecture

Carts and messages live in two custom tables; sequences, templates and suppressions in options; order links in HPOS-safe order meta. A cart becomes recovered only when its order reaches processing or completed after a reminder was sent or its link was clicked; otherwise it counts as bought anyway. The dashboard reports recovered revenue, recovery rate, a per-step funnel and top abandoned products. SMS goes through any Twilio-compatible API. Four more AI assistants (template writer, sequence builder, send-time insights, recovery insights) only ever produce drafts or read-only reports. The API client, settings, usage logging and admin kit come from a shared core used across DEV3's plugins.

What's in the download

  • The installable plugin zip: upload it through Plugins → Add New → Upload Plugin.
  • Full HTML documentation (installation, settings, hooks, FAQ).

Requirements

  • WordPress 6.0 or newer and PHP 7.4 or newer (tested on PHP 8.3)
  • WooCommerce 8.0 or newer, active (classic and block checkout are both supported, HPOS compatible)
  • A site that can send email; an SMTP plugin is recommended
  • Optional: a Google Gemini API key for personalised copy and the AI assistants. Without one, every recovery feature works with your approved templates
  • Optional: a Twilio-compatible SMS account for SMS steps

Learn more

Frequently asked questions

The complete source code (version 1.0.0) as a download from your account, with the setup and usage guides shown on this page. It is free: sign in to download it.

More from this author

View all

Related in CMS Extensions

View all