How to Build an Inventory System for E-commerce

Overselling is the symptom that pushes most Nigerian stores to act. A customer pays, the item is not there, the refund takes days, and the review that follows costs more than the order was worth. Behind it sits the same root cause every time: stock lives in several places at once — the website, the shop shelf, an Instagram post, a WhatsApp conversation — and none of them agree.
This guide covers how to build the system that makes them agree, whether you configure it on an existing platform or build custom software.
What an e-commerce inventory system must do
An e-commerce inventory system tracks what you own, where it is, what is promised to customers and what is genuinely available to sell, and it updates automatically as orders, deliveries, returns and adjustments happen.
Four quantities must be distinguishable at all times:
| Quantity | Meaning | Used for |
|---|---|---|
| On hand | Physically in your possession | Stock counts and valuation |
| Reserved | Allocated to paid or pending orders | Preventing double sales |
| Available | On hand minus reserved | What the website may sell |
| On order | Ordered from a supplier, not yet received | Purchasing decisions |
Most stores track only "on hand" and treat it as available. That single conflation causes the majority of overselling incidents.
Step 1: Get the SKU structure right
A stock keeping unit is the smallest thing you count. If a product comes in three sizes and two colours, that is six SKUs, not one product.
Rules that save pain later:
- One SKU, one physical item. Never share a SKU across variants.
- Keep codes short, readable and stable. For example, a pattern such as category-product-variant:
SKN-SRM-30ML,ACC-CSE-IP14-BLK. Staff will read these aloud on the phone. - Never reuse a retired SKU code. Historical reporting breaks when codes are recycled.
- Add a barcode field even if you do not scan yet. Manufacturer barcodes make future scanning cheap.
- Record supplier code separately from your own SKU, so purchase orders match supplier invoices.
- Bundles are their own SKUs with a component list, so selling a bundle deducts each component.
Spend a day on this before anything is built. Renaming SKUs after 18 months of sales history is expensive and error-prone.
Step 2: Establish one source of truth
Decide which system owns stock levels. Everything else reads from it.
Three common patterns:
- The online store owns stock. Simplest for online-only businesses. The store platform holds quantities; the shop, if any, records sales into the same system.
- A separate inventory or ERP system owns stock, and the store reads from it. Right when you have a warehouse, several sales channels and purchasing to manage.
- A point-of-sale system owns stock, and the website syncs. Common for retailers who started with a physical shop.
The wrong pattern is "both own it". Two-way sync between two systems that both think they are authoritative produces conflicts nobody can unravel.
Whichever you choose, define the sync rules explicitly: how often, in which direction, what happens on conflict and what happens when the connection fails. A failed sync should raise an alert, not silently leave the website selling items you no longer have.
Step 3: Reserve stock at checkout to stop overselling
Reservation is the mechanism that converts inventory data into a promise you can keep.
How it should work:
- When a customer begins checkout, the system places a temporary hold on the items for a defined window, typically 10–20 minutes.
- If payment succeeds, the hold converts to a reservation attached to the order.
- If payment fails or the window expires, the hold releases automatically and the stock returns to available.
- When the item is picked and dispatched, the reservation converts to an actual deduction from on hand.
- If the order is cancelled or returned to stock, the deduction reverses with a movement record.
This matters more in Nigeria than in markets with instant card-only checkout. Bank transfer payments can take minutes to confirm, and a customer who pays by transfer expects the item to still be there when the confirmation lands. Without a hold, a card buyer can take the last unit during that window.
For pay-on-delivery orders, decide deliberately: reserve on order (safer for the customer, riskier for you if refusal rates are high) or reserve on confirmation call. Whichever you pick, apply it consistently and set an expiry so unconfirmed orders release stock.
Step 4: Record every stock movement
Never let a quantity change without a record. The movement log is what makes discrepancies solvable.
Each movement should capture: SKU, quantity, direction, reason, location, reference document, user and timestamp.
Reason codes worth having from day one:
- Goods received from supplier
- Sale dispatched
- Customer return to stock
- Customer return written off as damaged
- Damaged or expired write-off
- Transfer between locations
- Stock count adjustment
- Sample, gift or staff purchase
- Theft or loss
The last two are uncomfortable but necessary. If "adjustment" is the only reason code available, every problem hides inside it and you learn nothing.
Step 5: Set reorder points and safety stock
Stockouts are quieter than overselling but more expensive over a year: the sale simply never happens.
A workable calculation for each fast-moving SKU:
- Average daily sales over a recent period, ideally excluding abnormal spikes.
- Lead time in days: order placed to goods on shelf, including customs clearance for imports.
- Safety stock: extra cover for demand variability and supplier lateness.
- Reorder point = (average daily sales × lead time) + safety stock.
Example arithmetic (illustrative): a SKU selling 8 units a day, with a 12-day lead time and 5 days of safety stock, has a reorder point of (8 × 12) + (8 × 5) = 136 units. When available stock falls to 136, purchasing should place an order.
Nigerian adjustments to that arithmetic:
- Imported goods need longer, more variable lead times and more safety stock, because shipping and clearance vary.
- Exchange rate movement changes the cost of waiting. If landed cost is rising, buying earlier in larger quantities may be cheaper, balanced against tying up cash.
- Seasonal peaks around December and major holidays need reorder points raised weeks ahead, not when the alert fires.
Automate the alert. A weekly report of SKUs below reorder point, sent to whoever buys, is one of the highest-value features in the whole system.
Step 6: Handle multiple locations and channels
Once you have a shop and a warehouse, or a warehouse in Lagos and a small stock in Abuja, quantities must be tracked per location, with transfers recorded as movements.
For channels, the question is which channels can draw on which location:
| Channel | Typical stock source | Sync risk |
|---|---|---|
| Your website | Warehouse, or all locations combined | Low if it owns stock |
| Physical shop or POS | Shop location only | Medium: offline sales must post back |
| Instagram and WhatsApp selling | Usually the same pool as the website | High: staff sell from chat without recording |
| Marketplaces such as Jumia, Konga or Jiji | A separate allocation or the shared pool | High: marketplace penalties for cancelled orders |
The practical answer for WhatsApp and Instagram sales is to create the order in the same system, even if the conversation happened in chat. A simple internal order form that staff fill in during the chat keeps stock accurate and gives you reporting on a channel that otherwise stays invisible.
For marketplaces, many sellers allocate a fixed quantity to each marketplace rather than sharing the full pool, accepting slightly lower availability in exchange for never cancelling a marketplace order.
Stock counts, shrinkage and costing
Systems drift from reality. Counting is how you correct it.
- Cycle counting beats annual stocktakes: count a subset of SKUs weekly, prioritising high-value and fast-moving items. The store stays open and errors surface early.
- Blind counts — staff count without seeing the system quantity — give honest numbers.
- Investigate before adjusting. A large variance is usually a missing movement record, not vanished goods.
- Track shrinkage per period by category. Persistent losses in one category point to a process problem or a control problem.
On costing, record the landed cost per receipt: supplier price, freight, duty, clearing and local transport. For imported goods this can differ substantially from the invoice price, and margin reports built on invoice price alone will be optimistic. Where costs change between batches, decide a consistent costing method with your accountant and apply it in the system.
Build routes and indicative costs
| Route | What it involves | Indicative cost | Best for |
|---|---|---|---|
| Configure your existing platform | Variants, stock rules, low-stock alerts, disciplined process | ₦80,000–₦400,000 | Stores under about 200 SKUs, one location |
| Platform plus inventory app or plugin | Adds purchase orders, multi-location, reporting | ₦300,000–₦1,500,000 plus monthly fees | Growing stores, two or three channels |
| Off-the-shelf inventory or ERP software | Established product, priced per user per month, usually in USD | Subscription plus ₦500,000–₦3,000,000 setup and integration | Stores with warehousing and purchasing teams |
| Custom inventory system | Built to your process, integrated with store, POS and accounting | ₦1,500,000–₦8,000,000+ | Unusual processes, many locations, manufacturing or assembly |
Indicative 2026 ranges; actual quotes vary with scope, vendor and exchange rate. Compare two or three written quotations on identical scope.
Recurring costs: hosting, maintenance at ₦20,000–₦150,000 per month for a store-integrated module, barcode scanners and label printers if you scan, and subscription fees in USD for off-the-shelf tools, which move with the exchange rate.
What changes for Nigerian e-commerce
Import lead times dominate planning. For imported stock, the gap between ordering and selling can be weeks, and it varies. Safety stock and reorder points must reflect that variability rather than an optimistic average.
Exchange rate volatility affects replenishment decisions, not just prices. Your system should record landed cost per batch so you can see real margin as costs move.
Cash sales and chat sales bypass the system unless you design for them. Staff will sell over WhatsApp. Give them a fast way to record it in under 30 seconds, or accept that your numbers will be wrong.
Power and connectivity interrupt updates. Offline-tolerant tools for shop staff, or a queue that syncs when the connection returns, prevent lost movements.
Returns are often informal. A returned item that goes back on the shelf without a movement record produces a phantom shortage. Make return-to-stock a one-tap action.
Several small locations are common — a shop, a store room, a relative's place used for overflow. Track them as locations rather than pretending stock is all in one place.
Example (hypothetical): a Lagos phone accessories retailer
Example (hypothetical): a retailer with a shop in Ikeja, a small warehouse, a website, an active Instagram page and a Jumia store carries about 600 SKUs and was overselling roughly one order a day.
What the build addressed:
- SKU restructure: 600 SKUs given a consistent code pattern, manufacturer barcodes recorded.
- Warehouse designated as the source of truth; shop and website both post movements to it.
- Fifteen-minute checkout holds introduced, with a longer hold for bank transfer payments awaiting confirmation.
- Instagram and WhatsApp sales entered through a one-screen internal order form used during the chat.
- A fixed allocation reserved for the marketplace channel to avoid cancelled marketplace orders.
- Weekly cycle counts of the top 50 SKUs by value and by movement.
- A Monday reorder report listing SKUs below reorder point with supplier and lead time.
The two changes that removed most of the overselling were the checkout hold and the chat order form. Neither was technically complex; both were process decisions the software then enforced.
Mistakes to avoid
- Treating on-hand as available. Reserved stock must be subtracted before the website decides what it can sell.
- Letting chat sales live in chat. Unrecorded sales guarantee inaccurate stock and hide your best channel's performance.
- Two-way sync between two authoritative systems. Pick one owner of truth.
- Adjustments without reasons. You lose the ability to diagnose shrinkage.
- No expiry on holds. Abandoned checkouts lock stock and create false stockouts.
- Reorder points set once and never reviewed. Demand and lead times change; review quarterly.
- Ignoring landed cost. Margin reports based on invoice price flatter imported products.
- Buying complex software before fixing the process. A system enforces whatever process you have, including a bad one.
Implementation checklist
- SKU structure defined, documented and applied to every product and variant
- Source of truth chosen and sync direction documented
- Four quantities tracked: on hand, reserved, available, on order
- Checkout holds with expiry configured, including a transfer-payment rule
- Movement log with reason codes in place
- Locations set up, transfers recorded as movements
- Chat and marketplace sales captured in the same system
- Reorder points and safety stock calculated for fast-moving SKUs
- Weekly low-stock report going to the buyer
- Cycle counting schedule agreed and blind counts used
- Landed cost recorded per receipt
- Staff trained, with a one-page guide for the common actions
Conclusion
A good e-commerce inventory system is less about software features than about a few enforced rules: one SKU per physical item, one system that owns stock, stock reserved the moment a customer commits, every movement recorded with a reason, and reorder points that fire before you run out. Get those right on whatever platform you already use, then invest in custom software when your process genuinely outgrows it.
If overselling, stockouts or chat sales that never reach your records are costing you orders, Linestech builds and integrates inventory systems for Nigerian online stores, including multi-channel stock sync and reorder reporting.
Frequently asked questions
At what point do I need a real inventory system?
Usually when one of these becomes true: more than about 100 active SKUs, more than one location, more than one sales channel, or a recurring overselling problem. Before that, a disciplined single spreadsheet plus your store platform's built-in stock tracking can be enough.
How do I stop selling the same item twice on Instagram and my website?
Record every Instagram or WhatsApp sale in the same system that powers the website, ideally at the moment the customer commits, using a fast internal order form. The chat is a conversation channel; it should not also be your stock ledger.
Should I use barcodes in a small Nigerian store?
Not immediately, but record manufacturer barcodes in the SKU data from the start. When volume justifies it, a basic scanner and label printer turn receiving and counting from a slow typing exercise into a quick scan, and error rates fall sharply.
What is safety stock and how much should I hold?
Safety stock is the buffer that covers demand spikes and late deliveries. A common starting point is the stock needed to cover a few days to a couple of weeks of average sales, with more for imported items with variable lead times and less for locally sourced goods you can replace quickly.
How often should I count stock?
Cycle count weekly, focusing on high-value and fast-moving items, and count everything at least once or twice a year. Frequent small counts catch errors while the cause is still traceable, which a single annual count never does.
Can my inventory system connect to my accounting software?
Yes, and it should. At minimum, purchases, sales and write-offs should reach your accounts. Integration can be automatic through an API or a scheduled export; agree the mapping with your accountant before development so the numbers reconcile.
What happens to stock when an order is refunded?
It depends on the reason. Returned saleable goods go back to stock with a return movement; damaged goods are written off with a separate reason code. The refund itself is a payment event, but the stock consequence must be recorded separately or your quantities drift.
Sources and further reading
Figures, platform rules and regulations change. These are the primary references behind this article and the places to check before you act on it.


