E-commerce · n8n

Recover Lost Sales: Automatic WhatsApp Reminders for Abandoned Shopify Carts

Automatically send a personalized WhatsApp message to customers who leave items in their Shopify cart without checking out. Recover revenue passively without any manual follow-up.

difficulty Intermediatesetup 45 minresult Every customer who abandons a Shopify cart receives a timely WhatsApp reminder with their cart details, nudging them to complete the purchase.
  1. 1

    Set Up the Shopify Trigger for Abandoned Checkouts

    Add a Shopify Trigger node to your workflow. In the Events field select checkout/create — Shopify fires this event whenever a checkout is created (which covers carts that are later abandoned). Enter your Shopify store URL and API credentials in the node's credential section. Enable the webhook so n8n starts listening for new checkouts.

  2. 2

    Filter Only Genuinely Abandoned Carts

    Add an IF node connected to the Shopify Trigger. Create a condition: check that {{$json["completed_at"]}} is empty. This ensures the workflow only continues for checkouts that were never completed. Orders that were actually purchased will have a completed_at timestamp and will be ignored.

  3. 3

    Extract Customer and Cart Details

    Add a Set node after the true branch of the IF node. Create the following fields: customerPhone mapped to {{$json["billing_address"]["phone"]}}, customerName mapped to {{$json["billing_address"]["first_name"]}}, cartUrl mapped to {{$json["abandoned_checkout_url"]}}, and totalPrice mapped to {{$json["total_price"]}}. These variables will be injected into your WhatsApp message.

  4. 4

    Send the WhatsApp Reminder via HTTP Request

    Add an HTTP Request node. Set Method to POST and paste your WhatsApp Business API endpoint URL (e.g. https://waba.360dialog.io/v1/messages for 360dialog). In Headers add D360-API-KEY with your API key. In Body choose JSON and paste a message body like: {"to": "{{$json[\"customerPhone\"]}}", "type": "text", "text": {"body": "Hi {{$json[\"customerName\"]}}, you left items worth ${{$json[\"totalPrice\"]}} in your cart! Complete your order here: {{$json[\"cartUrl\"]}}"}}. Store your API key safely in n8n's credential vault and reference it here.

  5. 5

    Activate and Test the Workflow

    Save and toggle the workflow to Active. To test, create a real checkout on your Shopify store and abandon it without completing payment. Within moments you should receive a WhatsApp message on the phone number entered at checkout. Check the Executions tab in n8n to confirm each step ran successfully and debug any issues with the HTTP response.

Frequently asked questions

How do I make sure reminders are sent only after a delay, not instantly?

Shopify's own abandoned checkout webhook fires after roughly 10 minutes of inactivity by default. If you need a longer delay (e.g. 1 hour), you can add a `Wait` node between the IF node and the Set node, configured to pause execution for your desired duration before sending the WhatsApp message.

What if the customer's phone number is missing from the checkout?

Add a second condition to your IF node checking that `{{$json["billing_address"]["phone"]}}` is not empty. If the phone field is blank the workflow will skip that checkout gracefully, avoiding failed API calls. You can also route the false branch to a Google Sheet to log carts with missing phone numbers for manual follow-up.

Is this compliant with WhatsApp's messaging policies?

Yes, as long as you use an approved WhatsApp Business API provider (such as 360dialog or Twilio) and send messages only to customers who provided their phone number and have an existing relationship with your store (i.e. initiated a checkout). You should also include an easy opt-out instruction in the message and comply with your local data protection regulations such as GDPR.

About this recipe. Recipes on FlowRecipesHub are written for business owners, not developers, and are tested before publishing — how recipes get made. Some ingredient links are affiliate links that cost you nothing — full disclosure.