E-commerce & Dropshipping · n8n

Forecast Restock Dates and Alert Before You Sell Out

Never surprise-stockout — use recent sales velocity to forecast when each SKU will run out and alert you in time to reorder.

difficulty Advancedsetup 45 minresult You know in advance when each product will sell out and can reorder before it does, avoiding lost sales.
  1. 1

    Schedule the Forecast

    Add a Schedule Trigger running daily.

  2. 2

    Compute Sales Velocity

    Add a Shopify/Code node calculating each SKU's recent daily sales rate.

  3. 3

    Forecast the Stockout

    Add a Code node projecting days-until-out from current stock and comparing to supplier lead time.

  4. 4

    Alert in Time

    Add an IF and Slack node warning when a SKU will run out before a reorder could arrive.

  5. 5

    Activate and Test

    Activate the workflow and feed a fast-selling test SKU. Confirm the forecast alert fires.

Frequently asked questions

How far ahead should it alert?

Alert when days-of-stock drops below the supplier lead time plus a safety buffer.

Can it account for seasonality?

Weight recent velocity or apply seasonal multipliers so forecasts reflect demand trends.

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.