WooCommerce Integration

No Code

Set up cart recovery for your WooCommerce store in under 3 minutes. Works with all themes and is HPOS compatible.

3
minutes

Average setup time

Plugin installation + API key = done!

Requirements

WP 6.0+
WordPress Version
WC 7.0+
WooCommerce Version
PHP 7.4+
PHP Version

Step 1: Install the Plugin

bash
# Option 1: Install from WordPress.org
Go to WordPress Admin → Plugins → Add New
Search for "Retake Cart Recovery"
Click "Install" then "Activate"

# Option 2: Manual ZIP Upload
Download the plugin ZIP from our website
Go to WordPress Admin → Plugins → Add New → Upload Plugin
Select the ZIP file and click "Install Now"
02

Get Your API Key

Sign up for a Retake account and copy your API key from the dashboard.

Get API Key
03

Configure the Plugin

Go to WooCommerce → Settings → Retake and paste your API key.

  • The settings page is under WooCommerce → Settings → Retake tab
  • Paste your API key and click "Save Changes"
  • Click "Test Connection" to verify everything works

Plugin Features

HPOS Compatible

Works with WooCommerce High-Performance Order Storage.

Smart Debouncing

Prevents API spam during rapid cart updates.

Server-Side Only

API key never exposed to frontend. 100% secure.

Zero Performance Impact

Async tracking with no blocking operations.

Advanced: Custom Theme Integration

If you need more control or are using a heavily customized theme, you can add tracking manually:

functions.php
php
// In your theme's functions.php or custom plugin
add_action('woocommerce_add_to_cart', 'retake_track_cart_update', 10, 6);
add_action('woocommerce_cart_item_removed', 'retake_track_cart_update');
add_action('woocommerce_thankyou', 'retake_track_conversion');

function retake_track_cart_update() {
    $cart = WC()->cart;
    $items = [];
    
    foreach ($cart->get_cart() as $item) {
        $product = $item['data'];
        $items[] = [
            'id' => $product->get_id(),
            'name' => $product->get_name(),
            'price' => $product->get_price(),
            'quantity' => $item['quantity']
        ];
    }
    
    wp_remote_post('https://retakeapi.com/api/v1/track', [
        'headers' => [
            'X-API-Key' => get_option('retake_api_key'),
            'Content-Type' => 'application/json'
        ],
        'body' => json_encode([
            'event' => 'INTENT',
            'type' => 'cart',
            'userId' => WC()->session->get_customer_id(),
            'email' => WC()->customer->get_email(),
            'value' => $cart->get_total('raw'),
            'items' => $items
        ]),
        'timeout' => 5,
        'blocking' => false // Non-blocking!
    ]);
}

Troubleshooting

Connection Test Failed?

If the "Test Connection" button shows an error:

  1. Double-check your API key (no extra spaces)
  2. Make sure your server can make outbound HTTPS requests
  3. Check if any firewall or security plugin is blocking external APIs
  4. Try disabling other plugins temporarily to rule out conflicts