Multi-Step Abandoned Cart Recovery: complete guide
Install, configure and run abandoned cart recovery: on-brand multi-step email sequences, escalating vouchers, one-click cart restore, targeting and per-step statistics for PrestaShop 8 and 9.
Overview
The Multi-Step Abandoned Cart Recovery module (datafireflycartrecovery) detects abandoned carts and follows up with your customers through a sequence of scheduled emails. Each step has its own delay, content per language and an optional voucher whose incentive can grow from one step to the next. A signed link lets the customer get their cart back in one click, with the voucher already applied, and the dashboard measures the revenue actually recovered, step by step.
On average, nearly 7 out of 10 carts are abandoned before payment. A well-tuned sequence (a simple reminder, then a moderate discount, then a stronger offer with free shipping) recovers part of that revenue with no manual work.
Compatibility
- PrestaShop 8.0 to 9.x
- PHP 8.1 to 8.3
- Single store and multistore (campaigns, carts and statistics kept separate per store)
- Interface: FR, EN, ES, DE, IT, PL
- Email templates: FR, EN, ES, DE, IT, PL, NL. Any other installed language automatically gets an editable copy of the English template.
- Compatible with the official GDPR module
psgdpr - PSR-4 architecture without Composer, no external dependency
Installation
- In the back office, open Modules > Module Manager.
- Click Upload a module and select
datafireflycartrecovery.zip. - Click Configure to set the general settings and the email appearance.
- Set up the scheduled task (next section), then send yourself a test email from a step.
Installation creates the module tables, registers its hooks, adds the Cart recovery tab and a default three-step campaign: +1 h (simple reminder), +24 h (-5% voucher) and +72 h (-10% voucher and free shipping).
Updating from a previous version
Upload the new ZIP: the upgrade scripts run automatically.
- To 1.3.5: the reminder voucher can no longer be combined with another promo code. The script registers two new hooks. No database change.
- To 1.3.4: fixes a blank page “If no employee is assigned in the context, cart ID must be provided to this method” when a cart is saved outside a browsing session (webservice, connector, payment webhook, script), the “Send now” button outside the sending window, and shifted due dates when the MySQL server does not use the store time zone. No database change.
- To 1.3.1: fixes the 500 error on the cron URL on PrestaShop 8. No database change.
- To 1.3.0: adds targeting by groups and categories and the appearance settings. Emails switch to a white header with the store logo, and the original blue stays the accent color. Adjust in Email appearance if needed.
- To 1.2.0: registers the new hooks (GDPR, email headers, language added) and creates missing email templates for installed languages.
If your store was on 1.1.0, the update requalifies carts wrongly counted as recovered (orders placed without any reminder email). The displayed recovered revenue goes down: that is the correct figure. Test the update on a staging store before production.
Scheduled task (cron)
The module works through regular runs triggered by a token-secured URL. On each run:
- Scan: carts inactive for longer than the abandonment delay are qualified (targeting, cooldown) and their steps scheduled.
- Sending: due emails go out, respecting every safeguard.
- Cleanup: module vouchers expired for 7 days and never used are deleted.
The exact URL, with its token, is shown on the dashboard (Set up button, with one-click copy) and in the module configuration:
https://YOUR-STORE/index.php?fc=module&module=datafireflycartrecovery&controller=cron&token=THE_TOKEN
Schedule a call roughly every 10 minutes:
*/10 * * * * curl -s "https://YOUR-STORE/index.php?fc=module&module=datafireflycartrecovery&controller=cron&token=THE_TOKEN" >/dev/null 2>&1
A lock guarantees that only one run happens at a time: two simultaneous calls never send the same email twice.
Processing status
The top of the dashboard shows the status of the scheduled task: green if the last run was less than 30 minutes ago, orange up to 3 hours, red beyond that or if it never ran. The Run now button runs immediately and shows the result: carts detected, emails sent, emails postponed outside the sending window, failures.
Without access to cron tasks
Enable Run without server cron in the module configuration. Processing is then triggered by store visits, at most every 10 minutes, after the page has been sent to the visitor: browsing is not slowed down.
This option depends on traffic: a store with no visits at night will send nothing until the first visit in the morning. A real cron remains more reliable. Do not share the cron URL token.
General settings
- Abandonment delay (60 min by default): inactivity after which a cart is considered abandoned.
- Emails per run (50 by default): number of emails processed on each run.
- Max emails per cart (3 by default): limit across all steps, 0 for no limit.
- Max lifetime (30 days by default): beyond this, an unconverted cart becomes Lost.
- Auto-login via the link (enabled by default): logs back in the registered customer who clicks the restore link, for 7 days after the email is sent.
- Sender email and name: when empty, the store’s are used.
- Run without server cron: see the previous section.
Email appearance
In the module configuration, the Email appearance block aligns reminders with your visual identity:
- Store logo: uses the email logo set in Design > Theme & Logo, otherwise the main logo. Its dimensions are calculated to display correctly in Outlook. Without a logo, the store name is shown.
- Accent color: button, links, line under the header and voucher block.
- Header background: white recommended if your logo is dark.
Text placed on these colors automatically switches to white or dark depending on contrast: a yellow button gets dark text, a navy button white text. The result is visible in the preview of each step.
Campaigns and targeting
A campaign groups a sequence of steps and its rules. The campaign screen shows its settings and, below them, the list of its steps.
- Minimum cart amount: 0 for no minimum.
- Sending window: time range outside which due emails are postponed (the window can span midnight).
- Cooldown (in days): a recipient who received a reminder for another cart during this period is not reminded.
- Target guests: includes guest customers or not.
- Exclude B2B accounts: excludes customers with a company, SIRET or VAT number filled in.
- Excluded customer groups: no email for customers belonging to one of these groups (resellers, staff).
- Excluded categories: a cart containing at least one product from these categories is not reminded (gift cards, low-margin products, prescription products). A search field filters the tree.
Sequence steps
- Position: order of the step.
- Delay after abandonment (in minutes): 60 = 1 h, 1440 = 24 h, 4320 = 72 h.
- Subject, button text and body per language: the body is written in a visual editor. When empty, the button text uses a translated default label.
- Active step: suspends a step without deleting it.
Variables
Usable in the subject, button text and body. Clicking a variable copies it.
{firstname},{lastname}: customer’s first and last name.{shop_name}: store name.{cart_total}: cart total in its currency.{voucher_code},{voucher_value},{voucher_expiry}: voucher code, value (for example 10% or €5.00) and expiry date. Empty if the step does not generate a voucher.
The body is inserted into a responsive template that adds the header, the cart summary (photos, combinations, total), the voucher block, the button and the footer with the unsubscribe link. A clean plain-text version is generated for mail clients that do not display HTML.
Preview and test email
Once the step is saved:
- The Preview button in each language tab (or the eye icon in the step list) opens the final rendering, with a desktop / mobile toggle.
- The Send a test email block sends the step to the address and in the language of your choice. The subject is prefixed with [TEST].
Preview and test use the saved version of the step and the most recent real cart of the store, with the dummy code DFCR-TEST42. No voucher is created, no statistic is changed, and the button link leads to the cart page without restoring a customer’s cart.
Vouchers
Each step can generate a voucher at sending time:
- Type: percentage or fixed amount (tax incl. or excl.).
- Value and minimum amount.
- Validity in days.
- Free shipping, alone or combined with the discount.
- The voucher is single use and time limited. It is tied to the customer for registered accounts. For guests it is not tied to the account, because PrestaShop creates a new guest account for each order: the code stays secret and usable only once.
- No stacking with another promo code: if the customer enters another code while a reminder voucher is in the cart, or the other way round, the code is refused with the message “This promo code cannot be combined with another promo code.” and the code already in the cart is kept. Automatic cart rules without a code (free shipping over X, for example) can still be combined.
- Escalation without stacking: when a new step generates a voucher, the previous unused voucher of the same cart is disabled.
- Cleanup: vouchers expired for 7 days and never used are deleted automatically.
Good practice: no discount at the first step, then a gradual escalation (-5%, then -10% with free shipping). The dashboard shows the revenue attributed to each step: you can see whether the strongest discount earns more than it costs.
One-click cart restore
Each email contains a signed link (HMAC). On click:
- the cart is rebuilt and the customer lands on their cart page;
- the voucher of the clicked email is applied automatically (any previous reminder voucher is removed), unless the cart already contains another promo code, in which case the customer’s code is kept;
- the registered customer is logged back in if the option is enabled and the email is less than 7 days old; the address chosen in the cart is kept;
- the click is recorded.
Any change to the link parameters invalidates it. A cart that has already been ordered redirects to the home page. If another customer is logged in on the browser, their session and cart are left untouched and the cart from the email is not restored.
How a sequence runs
- Resume: if the customer comes back to edit their cart, pending reminders are suspended. If they leave again, the sequence resumes at the next step without resending a step already received.
- Old carts: a cart inactive for more than 7 days is never reminded. After a long cron outage, the first run therefore does not email customers who left weeks ago. If the customer comes back to the cart, it becomes eligible again.
- Unavailable products: if no product in the cart can be ordered anymore (out of stock with backorders disabled, product disabled), the step is skipped. Later steps stay scheduled in case of restock.
- Sending failure: on an SMTP error, the email is retried 15 then 30 minutes later. After 3 failures it is marked as failed with the error message, and the voucher created is deleted.
- Order: when an order is validated, the remaining reminders are cancelled.
Tracking and attribution
- Opens: invisible pixel in each email.
- Clicks: click on the button or the restore link.
- Recovery: a cart counts as Recovered only if at least one reminder email was sent before the order. An order placed before any email gets the Ordered without reminder status and is not included in recovered revenue.
- Per-step attribution: each recovered cart is credited to the last email sent before the purchase.
Dashboard
- Period: 7, 30 or 90 days.
- Indicators: carts detected and abandoned value, recovered carts and recovery rate, emails sent, open and click rates, emails waiting to be sent, recovered revenue.
- Chart of detections and recoveries per day.
- Per-step performance of the active campaign: sent, opened, clicked, click rate, recovered carts and attributed revenue.
Tracked carts
The Carts tab lists tracked carts with a status filter, search (email, name or cart ID), pagination and CSV export of the filtered results. Each row shows the customer, amount, status, number of emails sent and scheduled, a link to the cart and, when relevant, to the order in the back office. The exclusion icon stops all reminders for a cart.
| Status | Meaning |
|---|---|
| Active | Cart in progress, not abandoned yet |
| Reminder in progress | Sequence scheduled or being sent |
| Recovered | Order placed after at least one reminder email |
| Ordered without reminder | Order placed before any email, not attributed |
| Lost | Sequence finished or tracking period exceeded |
| Excluded | Filtered by the campaign (amount, guest, B2B, group, category, cooldown) or excluded manually |
| Unsubscribed | The customer no longer wants reminders |
Send log
The Send log tab details every email: scheduled and sent dates, recipient, step, status (scheduled, sent, skipped, cancelled, failed), open, click, voucher code and reason (customer came back to the cart, limit reached, products unavailable, SMTP error…). For a scheduled email, you can send it now or cancel it. “Send now” sends the email immediately, even outside the sending window, and shows the result or the reason it was not sent.
GDPR and deliverability
- Each email contains an unsubscribe link. The address joins a persistent suppression list and pending sends are cancelled.
- The
List-UnsubscribeandList-Unsubscribe-Postheaders enable one-click unsubscribe from Gmail, Yahoo and other mail providers that require it for marketing emails. - Only carts linked to an email address (customer, or guest who completed the personal information step) are tracked: no address is captured before the customer submits it.
- With the official
psgdprmodule, the module appears in the list of modules processing data: exporting and deleting a customer’s data covers their tracked carts and reminder emails. - Deleting a customer account erases their tracked carts, send queue and events. Any opt-out stays on the suppression list.
- Uninstalling deletes the tables, configuration and admin tab.
FAQ and troubleshooting
No reminder is sent
Check the processing status at the top of the dashboard. If it is red, the cron task is not calling the URL (or not with the right token): use Run now to check, then fix the task or enable running without a server cron. Then check that the campaign and at least one step are active, that the current time is within the sending window, and look at the Send log: the reason for every skipped or failed email is listed there.
The customer cannot add their promo code
This is intended: the reminder voucher cannot be combined with any other promo code. The customer must first remove the code in the cart, then enter the other one. Automatic cart rules without a code are not affected.
Blank page “If no employee is assigned in the context, cart ID must be provided to this method”
This PrestaShop core message could appear with versions 1.0.0 to 1.3.1 when a cart was saved outside a browsing session (webservice, connector, payment webhook, script). Update to 1.3.4 or later.
The cron URL returns a 500 error
On PrestaShop 8, versions 1.0.0 to 1.3.0 caused a 500 error on the cron URL. Update to 1.3.1 or later and check the version shown in the Module Manager. If the error persists, enable PrestaShop debug mode or check the server PHP logs to read the exact message.
A cart does not appear in the list
A cart is only tracked when it is linked to an email address: logged-in customer, or guest who completed the personal information step. It becomes abandoned after the abandonment delay (60 minutes by default) and on the next cron run.
My logo does not appear or is unreadable
Check that the Store logo option is enabled and that a logo is set in Design > Theme & Logo. If your logo is dark, choose a light header background. Some mail clients block images by default: the store name is then shown instead.
The test email does not arrive
Check that the step has a subject in the chosen language and that the store can send emails (Advanced Parameters > E-mail, PrestaShop test email button). Also check your spam folder.
Can a customer receive too many emails?
No: the emails-per-cart limit, the per-recipient cooldown and the sending window control the frequency. An order or an unsubscribe cancels the remaining reminders.
Is the module multistore compatible?
Yes. Campaigns, tracked carts, appearance settings and statistics are kept separate per store.
Is it compatible with PrestaShop 9?
Yes. The module is compatible with PrestaShop 8 and 9 and follows the PS9 API changes (price formatting via the Locale API, controllers, email sending).