Skip to content

Using waitlists

Waitlist is a free WooCommerce back-in-stock plugin. On an out-of-stock or backorder product it shows an email form with a consent checkbox. When you set the product, or one of its variations, back to In stock, every waiting subscriber gets a restock email automatically, sent in batches of 50 through the WooCommerce mailer.

This walkthrough follows one back-in-stock cycle end to end: a shopper signs up on an out-of-stock product, you restock it, and every pending subscriber is emailed automatically.

When a product is out of stock or on backorder, Waitlist renders its form in the product summary, an email field, a required consent checkbox, and a submit button. A logged-in customer’s email is pre-filled.

The shopper enters an email, ticks consent and submits. The submit is an asynchronous fetch to admin-ajax.php (action restock_waitlist_subscribe, nonce-checked), no page reload. The button shows its Sending… busy label, the form sets aria-busy, and the result is announced in an aria-live region: success, invalid email, or missing consent. A confirmed signup resets the form and plays a one-shot success animation (suppressed under prefers-reduced-motion).

Server-side, the same email on the same product is deduplicated by a unique key, so a second signup updates the existing row rather than creating a duplicate. If the row was already notified, re-subscribing reactivates it.

On a variable product the form is output hidden. WooCommerce’s variation script fires found_variation; Waitlist checks whether that variation is out of stock or on backorder and, if so, reveals the form and stores the variation ID in the hidden product_id field. Choosing a different, in-stock variation hides it again. This is the one place Waitlist relies on jQuery, it listens to WooCommerce’s own variation events, which are jQuery-based; the submit itself is plain fetch.

If the shopper somehow submits while still on the variable parent (no variation chosen), the server rejects it with the variation required message.

Set the product (or variation) back to In stock. When WooCommerce fires woocommerce_product_set_stock_status or woocommerce_variation_set_stock_status with instock, Waitlist queues the mailing for that product ID and, for a variation, also for its parent, so shoppers who signed up on the parent are told too.

The mailing runs in the background on the plogins_waitlist_notify_batch hook: through Action Scheduler (group plogins-waitlist, visible under WooCommerce > Status > Scheduled Actions) when it is loaded, otherwise through WP-Cron. Each batch emails up to 50 waiting subscribers, oldest signup first, and queues the next batch until the list is done. Each subscriber emailed successfully is marked notified, so nobody is contacted twice. If the product cannot be loaded when a batch runs, the batch is retried up to three times, five minutes apart. There is nothing to set up beyond working WP-Cron or WooCommerce’s Action Scheduler.

The notification is a WooCommerce email, Back in stock (Waitlist), listed under WooCommerce > Settings > Emails. It uses your WooCommerce email header, footer and colours, and can be switched off, given its own subject and heading, or sent as plain text there. Defaults:

Part Default
Subject Product back in stock - {product_name} (or the subject saved in Waitlist’s older settings)
Heading {product_name} is back in stock
Intro Product {product_name} is back in stock. (Waitlist’s intro setting overrides it)
Closing the outro text from Waitlist’s settings, or a default line pointing to the leave link

The email shows the product image, a link to the product and a link to leave the waitlist. It also carries List-Unsubscribe and one-click List-Unsubscribe-Post headers. The leave link works for guests too: it is signed per subscription and email address, and the leave page allows 20 attempts per IP address every 10 minutes.

Delivery depends on your WordPress email setup (an SMTP plugin or your host). If a test email never arrives, check mail delivery before debugging Waitlist.

Logged-in customers see a Waitlists tab listing their active (not-yet-notified) signups, matched by user ID or by the email on the account, each with the product’s current stock status and a Leave waitlist button. Leaving is an AJAX call (restock_waitlist_unsubscribe, nonce-checked, logged-in only) that removes the row in place; clearing the last row reloads the empty state. Guests have no account view but still receive the restock email.

By default the form is added to the single-product summary. To put it elsewhere in a custom layout, use the shortcode:

[restock_waitlist]
[restock_waitlist id="123"]

id targets a specific product; without it the shortcode uses the current product in the loop. Either way the form still renders only when that product is out of stock or on backorder, and only while Show form on product page is on, with that setting off the shortcode returns nothing.

Open WooCommerce > Waitlist > Subscribers for a list with Total, Waiting and Notified counts. Each product link on a subscriber jumps to its edit screen. Append ?product_id=123 (or follow a per-product link) to filter to one product, note the filtered view shows that product’s waiting subscribers only, while the unfiltered view shows everyone. The list shows 50 rows per page. Export CSV downloads the current view as restock-subscribers.csv with the columns ID, Product ID, Email, User ID, Notified, Created At and Notified At, nonce-protected, handy for gauging demand before you reorder.

Waitlist loads templates through a theme-aware loader and exposes two filters around it. There are no shortcode-replacing or form-markup filters, to change markup, override the template (see Configuration).

// Adjust the variables passed into a Waitlist template.
add_filter( 'restock/template/args', function ( array $args, string $template ): array {
// $template is e.g. 'single-product/waitlist-form'.
// $args holds 'product', 'settings', 'email' (and 'subscriptions' for the account view).
return $args;
}, 10, 2 );
// Override which file is loaded for a template.
add_filter( 'restock/template/path', function ( string $path, string $template ): string {
return $path;
}, 10, 2 );

Other filters:

Filter Default What it controls
plogins_waitlist_should_notify true Return false to skip the mailing for a restock. Receives $product_id and the WC_Product.
plogins_waitlist_notify_batch_size 50 Subscribers emailed per background batch (minimum 1).
plogins_waitlist_subscribers_per_page 50 Rows per page on the Subscribers screen.
plogins_waitlist_pending_query_limit 5000 Cap on a full pending-subscriber read, used by the PRO add-on.
// Do not email anyone when a product in the "clearance" category is restocked.
add_filter( 'plogins_waitlist_should_notify', function ( bool $notify, int $product_id, WC_Product $product ): bool {
return has_term( 'clearance', 'product_cat', $product->get_parent_id() ?: $product_id ) ? false : $notify;
}, 10, 3 );

(waitlist/booted, and its older alias restock/booted, are internal boot signals, not public extension points.)

The form is server-rendered in PHP in the normal document flow on the product summary, no lazy injection, so no Cumulative Layout Shift. The only front-end script is the small fetch submit handler, enqueued defer in the footer on single-product pages (and on the My Account waitlists endpoint). The email field has a real label as screen-reader text, the consent checkbox is genuinely required, the form reports aria-busy while submitting, and results are announced via aria-live="polite", built with WCAG 2.2 AA in mind.

  • Shortlist: with Shortlist’s setting on, an out-of-stock or backorder simple product on the wishlist shows this same sign-up form, so the shopper joins without opening the product page. An out-of-stock variable product shows a Notify when available button that opens the product page.
  • Rezervo: a product or variation marked as a pre-order in Rezervo shows only Rezervo’s Pre-order button, with no waitlist form, and the sign-up handler refuses it too. On a variable product with mixed variations, picking a pre-order variation hides the form, and picking an out-of-stock variation that is not a pre-order shows it. This needs Waitlist 1.1.5 and Rezervo 1.1.5 or later, with Rezervo’s pre-orders switched on.

Right after the stock status changes to In stock, Waitlist queues the first batch. It runs on the next Action Scheduler or WP-Cron tick, so on a quiet site the emails can arrive a few minutes later.

Yes. It is a regular WooCommerce email, so it follows WooCommerce > Settings > Emails. To change the markup, copy emails/waitlist-restock.php or emails/plain/waitlist-restock.php from the plugin’s templates/ folder into yourtheme/woocommerce/ and edit the copy.

Through the leave link in the restock email, or the one-click unsubscribe their mail app offers from the List-Unsubscribe header. Logged-in customers can also use Leave waitlist in the My Account Waitlists tab.

Will a shopper be emailed twice for the same product?

Section titled “Will a shopper be emailed twice for the same product?”

No. A successfully emailed subscriber is marked notified and is skipped on the next restock. Signing up again for the same product reactivates that one row.