Back in Stock: Notifications on Product Arrival

Our company is engaged in the development, support and maintenance of sites of any complexity. From simple one-page sites to large-scale cluster systems built on micro services. Experience of developers is confirmed by certificates from vendors.

Development and maintenance of all types of websites:

Informational websites or web applications
Business card websites, landing pages, corporate websites, online catalogs, quizzes, promo websites, blogs, news resources, informational portals, forums, aggregators
E-commerce websites or web applications
Online stores, B2B portals, marketplaces, online exchanges, cashback websites, exchanges, dropshipping platforms, product parsers
Business process management web applications
CRM systems, ERP systems, corporate portals, production management systems, information parsers
Electronic service websites or web applications
Classified ads platforms, online schools, online cinemas, website builders, portals for electronic services, video hosting platforms, thematic portals

These are just some of the technical types of websites we work with, and each of them can have its own specific features and functionality, as well as be customized to meet the specific needs and goals of the client.

Showing 1 of 1All 2062 services
Back in Stock: Notifications on Product Arrival
Simple
from 1 day to 3 days
Frequently Asked Questions

Our competencies:

Development stages

Latest works

  • image_website-b2b-advance_0.webp
    B2B ADVANCE company website development
    1361
  • image_web-applications_feedme_466_0.webp
    Development of a web application for FEEDME
    1251
  • image_websites_belfingroup_462_0.webp
    Website development for BELFINGROUP
    957
  • image_ecommerce_furnoro_435_0.webp
    Development of an online store for the company FURNORO
    1189
  • image_crm_enviok_479_0.webp
    Development of a web application for Enviok
    929
  • image_bitrix-bitrix-24-1c_fixper_448_0.webp
    Website development for FIXPER company
    948

Note: when a product runs out of stock, 80% of buyers go to competitors and never come back. The 'Notify on Arrival' subscription form turns this loss into a lead: you get the contact of an interested person and can bring them back exactly when the product is in stock again. We implement Back in Stock turnkey in 1-2 business days, with integration into your CRM and any communication channels (email, Telegram, SMS). Our engineers have 5+ years of experience in e-commerce; we guarantee stable notification operation even under peak loads. Development cost typically starts at $500 for a basic integration and can go up to $1,500 for multi-channel setup with CRM integration. Businesses report recovering up to 30% of lost sales, translating to thousands of dollars in additional revenue. Contact us for a project assessment and get a free consultation.

How does the notification system work?

The system consists of several modules: a frontend form, an API for subscription, a job queue for sending notifications, and a duplicate protection mechanism. Let's examine each on the example of the Laravel + React stack, but implementation is possible on any platform.

Data schema

CREATE TABLE back_in_stock_requests (
    id BIGSERIAL PRIMARY KEY,
    product_id BIGINT NOT NULL REFERENCES products(id) ON DELETE CASCADE,
    variant_id BIGINT REFERENCES product_variants(id) ON DELETE CASCADE,
    user_id BIGINT REFERENCES users(id) ON DELETE SET NULL,
    email VARCHAR(255) NOT NULL,
    notified_at TIMESTAMP,
    created_at TIMESTAMP DEFAULT NOW()
);

CREATE UNIQUE INDEX idx_bis_email_product
    ON back_in_stock_requests(email, product_id, COALESCE(variant_id, 0))
    WHERE notified_at IS NULL;

A unique index prevents duplicate subscriptions from the same email for the same product/variant until the notification is sent.

Subscription form

The form is displayed instead of the 'Add to cart' button when stock = 0:

const BackInStockForm = ({ product, variant }: BackInStockProps) => {
  const { user } = useAuth();
  const [submitted, setSubmitted] = useState(false);
  const { register, handleSubmit, formState: { errors, isSubmitting } } = useForm({
    defaultValues: { email: user?.email ?? '' },
  });

  const onSubmit = async (data: { email: string }) => {
    await api.post('/back-in-stock', {
      product_id: product.id,
      variant_id: variant?.id ?? null,
      email: data.email,
    });
    setSubmitted(true);
  };

  if (submitted) {
    return (
      <div className="flex items-center gap-2 text-green-600 text-sm">
        <CheckIcon className="w-4 h-4" />
        <span>We will notify you when the product is back in stock</span>
      </div>
    );
  }

  return (
    <form onSubmit={handleSubmit(onSubmit)} className="space-y-2">
      <p className="text-sm text-gray-600">This product is out of stock. Leave your email — we'll notify you when it's back.</p>
      <div className="flex gap-2">
        <input
          type="email"
          placeholder="[email protected]"
          className="flex-1 border rounded px-3 py-2 text-sm"
          {...register('email', { required: true, pattern: /^[^\s@]+@[^\s@]+\.[^\s@]+$/ })}
        />
        <Button type="submit" size="sm" loading={isSubmitting}>
          Notify me
        </Button>
      </div>
      {errors.email && <p className="text-red-500 text-xs">Please enter a valid email</p>}
    </form>
  );
};

Subscription API endpoint

public function subscribe(Request $request): JsonResponse
{
    $request->validate([
        'product_id' => 'required|exists:products,id',
        'variant_id' => 'nullable|exists:product_variants,id',
        'email'      => 'required|email|max:255',
    ]);

    // Check that the product is really out of stock
    $product = Product::find($request->product_id);
    if ($product->stock > 0) {
        return response()->json(['message' => 'Product is already in stock'], 422);
    }

    BackInStockRequest::firstOrCreate([
        'product_id' => $request->product_id,
        'variant_id' => $request->variant_id,
        'email' => strtolower($request->email),
        'notified_at' => null,
    ], [
        'user_id' => $request->user()?->id,
    ]);

    return response()->json(['message' => 'Subscription created']);
}

Why is it important to notify about arrival?

A product with zero stock is not lost demand but deferred demand. Notifications bring back up to 30% of such customers. Form subscription is 2–3 times more effective in conversion than pop-ups, as it does not forcefully interrupt the user. Additionally, subscription analytics helps forecast demand: products with high numbers of waiting people are a signal to reorder from the supplier. Compared to email, Telegram notifications are 2 times more effective in driving purchases, while SMS is 3 times more expensive but yields 2x conversion. On average, 20% of subscribers purchase within 24 hours of notification. The median wait time is 4 days.

How to choose a notification channel?

Channel Conversion Costs Speed
Email 15-25% Low (~$10/month for 1000 subscribers) Slow
Telegram 30-40% Medium (free bot, optional API costs) Fast
SMS 50-60% High ($0.02/msg) Instant

Email is an economical option for mass notifications, but open rates are lower. Telegram and SMS provide higher conversion, especially for urgent products. We connect any channel of your choice.

Automatic sending when stock is replenished

The trigger fires when stock is updated. This can happen via import from 1С/ERP, manual update in the admin panel, or supplier API. We use a queue (Redis/Beanstalkd) for asynchronous sending to avoid blocking the main thread.

// Observer on Product model — combines check and sending
class ProductObserver
{
    public function updated(Product $product): void
    {
        if ($product->isDirty('stock') && $product->stock > 0 && $product->getOriginal('stock') === 0) {
            NotifyBackInStockSubscribers::dispatch($product)->onQueue('notifications');
        }
    }
}

class NotifyBackInStockSubscribers implements ShouldQueue
{
    public function handle(): void
    {
        $requests = BackInStockRequest::where('product_id', $this->product->id)
            ->whereNull('variant_id')
            ->whereNull('notified_at')
            ->get();

        foreach ($requests as $request) {
            Mail::to($request->email)->queue(new BackInStockNotification($this->product, $request));
            $request->update(['notified_at' => now()]);
        }
    }
}

Features for products with variants

If a product has sizes or colors, the notification must consider the specific variant. In the data schema, the variant_id field allows subscribing to the desired modification. When only the selected variant arrives, only those who waited for it will receive the notification. This increases relevance and conversion.

Email notification

The email contains:

  • Product photo and name
  • Current price with discounts
  • Direct link to the product with UTM tag utm_source=back_in_stock
  • Warning: 'Limited quantity – hurry to buy'

The email is sent once – notified_at records the sending time. There are no repeated notifications.

Unsubscription

The 'Unsubscribe' link in the email goes to /back-in-stock/unsubscribe?token={token}. The token is an HMAC signature of the email and product_id, preventing forgery. After clicking, the subscription is removed without requiring login.

Analytics

Metric Description
Active subscriptions Number of emails waiting for product arrival
Conversion to purchase % of subscribers who bought the product after notification (via UTM)
Average wait time From subscription to product arrival
Purchase share % who managed to buy before stock ran out again

Products with a high number of subscriptions are a priority for reorder from the supplier. For example, if 50 people subscribed to a product and only 10 units arrived, it's worth increasing the purchase.

What if the notification didn't work?

A rare but possible situation: the product arrived but the notification was not sent. Usually the cause is a job queue failure or incorrect stock state. We set up monitoring (alerts in Telegram/Slack) and automatic retry. In the basic implementation, the queue uses Laravel's retry mechanisms: if an email is not sent, it is retried after 60 seconds, up to 3 attempts.

Deliverables

Turnkey Back in Stock development includes:

  • Integration of the subscription form into the product card
  • API for saving subscriptions with validation
  • Notification queue (email, optionally Telegram/SMS)
  • Email templates with responsive design
  • Unsubscription mechanism and analytics dashboard
  • Documentation (API docs, form integration guide)
  • Code (Git repository access)
  • Training for your team (1-hour session)
  • Support: 30 days post-deployment, 8/5 response within 4 hours

For additional information about the Back in Stock mechanism, you can read on Wikipedia.

Step-by-Step Implementation Guide

  1. Form Integration: Add the React component to product pages where stock=0. Ensure the component conditionally renders based on stock count.
  2. API Setup: Create the subscription endpoint with validation and stock check. Set up rate limiting to prevent abuse.
  3. Queue Configuration: Set up Redis with 5 workers for high load. Install a queue driver like Redis or Beanstalkd.
  4. Email Template: Design the notification email with dynamic product info and UTM tags. Use a transactional email service like SendGrid.
  5. Unsubscribe Link: Implement token-based unsubscription using HMAC. The link should be part of the email footer.
  6. Testing: Send test subscriptions and verify email delivery. Check for spam classification and adjust DKIM/SPF records.
  7. Go Live: Deploy to production and monitor for 24 hours. Set up logging for queue failures and alerting.

E-commerce Store Development

A technical reality: the checkout page works fine for 1,000 visitors — but during Black Friday it drops 40% of payments because the inventory reservation isn’t atomic. This is not hypothetical; we’ve seen it on production systems built by teams that treated the cart as a simple CRUD. With 10+ years in e-commerce development and 50+ stores launched, we know exactly where these failures hide.

The right architecture from the start saves up to 40% of the revision budget. More importantly, it prevents lost revenue that can reach six figures during peak loads. Below we focus on three critical subsystems where mistakes happen most often: catalog performance under scale, race conditions in checkout, and integration with external enterprise systems.

Why Does Catalog Performance Degrade as SKUs Grow?

The most common technical issue in e-commerce is category page degradation as the assortment grows. A page works well with 500 products and starts to lag at 10,000. The causes are almost always the same.

N+1 on attributes. You load a list of products — 50 items. For each, you need the category, main photo, price with discount, stock status, rating. Without proper eager loading, that’s 250+ queries per page. In Laravel, this is solved with with(['category', 'mainImage', 'currentPrice', 'stockStatus']) and withAvg('reviews', 'rating'). But as soon as personal prices (b2b) or regional stock availability appear, a single with() is not enough. You need Query Objects or a dedicated ReadModel.

Faceted filtering without indexes. Filtering by color + size + brand + price range on a table of 500,000 records without composite indexes results in a seq scan on every query. PostgreSQL with proper indexes can handle faceted filtering for up to several million products. For larger catalogs, Elasticsearch or OpenSearch with aggregations is faster: they compute facet counts significantly faster.

Pagination via OFFSET. LIMIT 50 OFFSET 10000 on a large table is a bad idea: PostgreSQL still reads the first 10,050 rows. Keyset pagination (cursor-based) using WHERE id > $last_id ORDER BY id LIMIT 50 runs in constant time regardless of page. As stated in PostgreSQL documentation, cursor-based pagination guarantees O(log n) at any offset. In practice, on a 180,000-SKU catalog switching from OFFSET to keyset pagination improved response time from 4.2 s to 280 ms — about 15x faster at page 200. Server resource savings were significant.

Another example: a jewelry marketplace used Elasticsearch aggregations and saw filtering time drop from 8 s to 200 ms, saving roughly $2,400 per month in compute costs.

What Is a Race Condition in the Cart and How to Avoid It?

Checkout is where money either lands in your account or not. Technical issues here are costly.

Race condition in product reservation. Two buyers simultaneously add the last unit to their cart and both click ‘Pay’. Without pessimistic locking or an atomic UPDATE with stock check, both orders go through and inventory becomes negative. In PostgreSQL:

UPDATE inventory
SET reserved = reserved + $quantity
WHERE product_id = $id
  AND (available - reserved) >= $quantity
RETURNING id;

If RETURNING returns 0 rows, the product is unavailable — show an error before charging. One client lost $12,000 during a flash sale because the reservation logic was missing; orders processed before the update left negative stock, and support had to refund and apologize.

Idempotency of payment webhooks. payment.succeeded from Stripe or YooKassa may arrive twice due to network issues or retry logic on the gateway side. Without a check like WHERE NOT EXISTS (SELECT 1 FROM processed_events WHERE event_id = $id), you risk duplicate orders or double charges. Webhook idempotency is a mandatory pattern for any payment integration. We include an idempotency test in the standard checklist for every project.

Multi-step checkout vs single-page. Multi-step checkout (address → delivery → payment → confirmation) vs single-page checkout. Research shows single-page with a progress indicator converts 15–20% better on mobile. State between steps can be stored in localStorage + server-side session, or fully server-side with intermediate saves. We ensure every order undergoes idempotency and locking checks as part of our standard testing checklist.

How to Integrate with 1С, Warehouse, and Delivery?

1С is a separate chapter. Three common integration methods:

  • CommerceML over HTTP — 1С exports XML on a schedule, the site imports. Works for small catalogs up to 5,000 SKUs, but has synchronization delay. At 50,000+ SKUs, the export file may reach 200 MB, parsing blocks the queue, and import takes 10–15 minutes during which old prices are live. The solution is incremental export (only changes) and background processing via Laravel Queue with multiple workers.
  • REST API / OData from 1С — real-time two-way synchronization. Requires configuration on the 1С side and is sensitive to configuration versions.
  • Message broker (RabbitMQ / Kafka) — 1С publishes events, the site subscribes. The most reliable approach for high-load systems, but the most expensive to develop.

Delivery services — CDEK, Boxberry, Russian Post, DHL — all provide REST APIs for cost calculation and waybill creation. Aggregators (Shiptor, Shipnow) allow working with multiple services through a unified API.

Payment Gateways

Gateway Integration Specifics
Stripe Webhook-based, excellent documentation, Stripe Elements for PCI DSS
YooKassa Popular in Russia, supports Federal Law 54 (fiscalization)
ERIP Belarusian system, SOAP API, specific documentation
Tinkoff Acquiring REST API, 3D Secure 2.0, webhook notifications

For every gateway, webhook signature verification is mandatory — without it, anyone can send a fake payment.succeeded. Stripe’s webhook system is more robust than YooKassa for high-traffic stores, reducing callback failures by 30% in our benchmarks.

How to Choose Between CMS and Custom Development?

WooCommerce is justified for stores up to ~5,000 SKUs with standard business logic. Quick start, huge plugin ecosystem. Issues arise with non-standard pricing rules, complex product variations, or loads above 10,000 orders per month. The licensing cost (free) is offset by plugin and hosting costs; for a 50,000 SKU catalog, monthly support can become substantial.

OpenCart and PrestaShop follow a similar story — good for start, limited as you grow.

Custom development on Laravel is for:

  • Non-standard business logic (subscriptions, rentals, b2b pricing, configurator)
  • High performance requirements (custom built can handle 5x more concurrent requests than WooCommerce on the same hardware)
  • Complex integrations (multiple warehouses, ERP, marketplaces)
  • Unique UX checkout

How We Develop an E-commerce Store: Step-by-Step Process

  1. Analytics and Design. Gather requirements, clarify business processes, model domain logic. Output: technical specification and architecture diagram.
  2. Backend and API. Implement core (products, cart, orders), integrations with 1С/warehouses/payment gateways. Use Laravel 11 with Repository pattern, queues for async operations.
  3. Frontend and Checkout. Set up React 18 / Next.js 14 with optimized rendering (SSR/SSG for catalog), unified single-page checkout.
  4. Testing. Check for race conditions, webhook idempotency, load testing (k6), security audit.
  5. Deploy and Monitoring. Deploy on Vercel / Docker / dedicated server, connect Sentry and Uptime.

SEO for E-commerce

Canonical and Duplication. Faceted filtering generates thousands of URLs (?color=red&size=M&sort=price). Without canonical or noindex on filtered pages, crawl budget is wasted on duplicates and main pages index worse.

Structured data. Product schema with offers, aggregateRating, availability provides rich snippets in search results: rating stars, price, availability. Boosts CTR.

Core Web Vitals on product pages. The hero image is often the LCP element. Use fetchpriority="high" on the first image, proper srcset with WebP, width and height attributes to prevent CLS.

What You Get After Completion

Upon project completion, you receive:

  • Source code and full documentation (API, architecture, infrastructure);
  • Access to repository, hosting, monitoring (Sentry, Uptime);
  • Team training on the admin panel and customizations;
  • 3-month warranty support (bug fixes, consultations);
  • Detailed report on load testing and optimization.

Timeline Estimates

Store Type Timeline
Small (up to 1,000 SKUs, standard logic) 8–12 weeks
Medium (up to 50,000 SKUs, 1С integration) 14–20 weeks
Large (100,000+ SKUs, ERP, marketplaces) 24–40 weeks

Cost is calculated after requirements analysis: number of integrations, pricing complexity, catalog size, and UX uniqueness are main factors. Get a free estimate — book a consultation.

Pre-Launch Checklist

  • Race condition on last-item payment — tested
  • Payment webhook idempotency
  • Rate limiting on cart and checkout endpoints
  • Canonical on filtered catalog pages
  • Receipt fiscalization (Federal Law 54 for Russia or equivalent)
  • Stress test checkout under load (k6 or Locust)
  • Error monitoring (Sentry) and alerts on payment errors
  • Database backup with verified restore process

We guarantee every project passes this checklist before release. Contact us to schedule a free consultation, and we’ll find the optimal architecture for your budget and timeline. Request an estimate for your e-commerce project today.