Warehousing and inventory management

Customs warehouse types, 3PL and 4PL, FIFO and FEFO, ABC analysis, economic order quantity, safety stock and dwell time

15 min readLevel: BeginnerUpdated: Download PDF

Download this topic as a PDFA printable study note. It may be shared for educational purposes with credit to the source.

Download PDF
A selective pallet racking aisle in a warehouse with a reach truck putting a pallet away on an upper level
The two basic questions of warehousing: where should stock be held, and how much of it? Illustrative image (AI-generated).

Two questions: where to hold it, and how much?

Warehouse management decides where and under what status goods wait: in your own warehouse, in a logistics provider's warehouse, or in a customs warehouse under customs supervision? Inventory (stock) management decides how much to order and when. The two are linked: too much stock fills the warehouse and ties up capital; too little loses sales.

Types of storage

Type What it is for
Customs warehouse (antrepo) A place for goods under customs supervision, set up under conditions laid down by regulation. Goods placed there in line with the rules can stay without a time limit, and duties are not paid for that period
Temporary storage facility A shed, warehouse, yard or hangar where vehicles stop, berth or unload, in which goods presented to customs and not in free circulation wait
Free zone Operating requires a licence from the Directorate General of Free Zones; the document confirming the goods' customs status is called the Customs Status Certificate
Cross-dock Goods are not stored; they move from the receiving dock to the shipping dock or wait briefly in a buffer area near the docks

The definitions follow Türkiye's Ministry of Trade; the cross-dock definition comes from academic sources. Permits to open and operate customs warehouses and temporary storage facilities are issued by the Directorate General of Customs.

Other distinctions by function and structure are also used: open and closed warehouses, cold stores, distribution centres and so on. For temperature-controlled storage, see Reefer containers and the cold chain.

Customs warehouse types (A–F)

The customs warehousing guide of Türkiye's Ministry of Trade (Directorate General of Customs) groups types A, B and F as public customs warehouses and C, D and E as private customs warehouses.

  • Public customs warehouse: available to anyone for storing goods.
  • Private customs warehouse: reserved for goods belonging to the warehouse operator.

According to a reproduction of the Turkish Customs Regulation, the types are defined as follows:

Type Group Who is responsible?
A Public The operator keeps the stock records; if goods are missing, the operator is liable for the customs duties
B Public The user lodges the warehousing declaration and is responsible for the goods; the operator's liability is limited
C Private Operator and user are the same person, who is responsible for the goods
D Private Operator and user are the same person; paragraph 3 of Article 104 of the Customs Law applies
E Private Operator and user are the same person; under Article 93(4) of the Law the authorisation holder's storage place is treated as a customs warehouse, or warehousing rules apply to the goods even without a storage place
F Public A public customs warehouse operated by the customs administration

Check the article numbers: Sources cite these provisions under different article numbers (Arts. 328–329 in one, later articles in an older presentation). For official purposes, check the current Customs Regulation on mevzuat.gov.tr. For how customs warehousing works as a procedure, see HS codes and customs procedures in Türkiye.

3PL and 4PL

  • 3PL (third-party logistics): According to sources quoting the CSCMP glossary, outsourcing all or much of a company's logistics operations to a specialist company. The term dates back to the early 1970s.
  • 4PL (fourth-party logistics): Usually a separate entity, such as a joint venture or a long-term contract with a primary client. It acts as a single interface to several logistics service providers and ideally manages every aspect of the client's supply chain. According to the same source, the term was defined and trademarked by Accenture in 1996.

In short, a 3PL does the work; a 4PL manages the providers who do it. For other roles in logistics, see The parties in trade and logistics.

WMS: warehouse management system

A WMS is a software application that helps track and run a warehouse's day-to-day operations. If you work with a 3PL, it helps to agree at the contract stage which reports and stock data you will get from its WMS.

Picking order: FIFO, FEFO, LIFO

Method Rule
FIFO (first in, first out) The first item stored is the first shipped
FEFO (first expired, first out) The item with the shortest remaining shelf life is shipped first; this reduces waste and leaves the end user enough shelf life
LIFO (last in, first out) The most recently stocked item leaves first

The EU Good Distribution Practice guidelines for medicinal products for human use (2013/C 343/01) require stock to be rotated according to FEFO.

Physical flow and accounting are not the same thing. The order in which goods leave the warehouse and the method used to cost inventory in the accounts are separate concepts. According to KPMG, the LIFO cost method is prohibited under IFRS (IAS 2) and permitted under US GAAP.

ABC analysis

ABC analysis sorts stock items into three classes by their share of value. The general rule in course material is that about 20% of items account for about 80% of inventory value, while the remaining items account for a small share. The relationship is linked to the Pareto principle.

The proportions vary by business. In the examples in the same course notes, class A is ~15% of items and ~60% of value in one inventory, and ~30% of items and ~80% of value in another.

Class Typical picture Approach
A Few items, most of the value Control and attention concentrate here
B The middle group Moderate control
C Many items, a small share of value Managed with simple rules

Economic order quantity (EOQ)

Every order carries a fixed cost (preparing the order, arranging transport, receiving). Holding stock costs money too (space, capital, insurance, waste). Small, frequent orders raise the first; large, infrequent orders raise the second. The economic order quantity balances the two:

Q* = √(2DS / H)

  • D: Annual demand (units)
  • S: Cost per order
  • H: Annual holding cost per unit

Q* rises as the order cost rises and falls as the holding cost rises.

The model's assumptions: demand is constant, stockouts are not allowed, replenishment is instantaneous and the lead time is zero. Real life rarely fits these exactly; use the result as a starting point.

Origin: The formula goes back to Ford W. Harris's article "How Many Parts to Make at Once", published in Factory, The Magazine of Management in February 1913. The article was long cited incorrectly and was rediscovered by Erlenkotter.

Example: Annual demand 12,000 units, cost per order 150, annual holding cost per unit 4 (same currency).

Step Calculation Result
Economic order quantity √(2 × 12,000 × 150 ÷ 4) = √900,000 ≈ 948.7 → 949 units
Orders per year 12,000 ÷ 948.7 ≈ 12.65
Annual ordering cost 12.65 × 150 ≈ 1,897
Annual holding cost (average stock × H) 948.7 ÷ 2 × 4 ≈ 1,897

At the EOQ, the annual ordering cost and the annual holding cost come out equal.

Safety stock and reorder point

In reality, demand and lead times fluctuate. Safety stock is extra stock held against that uncertainty; the reorder point is the stock level at which you place an order.

Reorder point = expected demand over the lead time + safety stock

Safety stock = z × σ

  • σ: The standard deviation of demand over the lead time.
  • z: The factor for the target cycle service level. For 95%, z ≈ 1.65.

If both demand and lead time vary, σ = √(μ(t) × σ(d)² + μ(d)² × σ(t)²), where μ(d) and σ(d) are the mean and standard deviation of demand per period and μ(t) and σ(t) those of the lead time.

Example (with the demand above): With 360 working days a year, daily demand is 12,000 ÷ 360 ≈ 33.3 units. Say the lead time is 7 days and the standard deviation of lead-time demand is 36 units.

Step Calculation Result
Lead-time demand 33.3 × 7 ≈ 233 units
Safety stock (95%) 1.65 × 36 ≈ 59.4 → 60 units
Reorder point 233 + 60 ≈ 293 units

When stock falls to 293 units, an order of about 949 units is placed.

Service level and fill rate are different. The cycle service level is the probability of not running out during a replenishment cycle; the fill rate is the share of demand met from stock. In the University of Iowa lecture example, a reorder point set for a 99% fill rate gives only about an 81.6% cycle service level. Be clear about which one you mean when setting a target.

Enter your own demand, cost and lead time figures to see the economic order quantity and reorder point.

The classic EOQ model assumes constant demand, no stockouts, each order arriving in one batch and no quantity discounts. The result is a starting point; the values are examples.

Worked example step by step
StepCalculationResult
Economic order quantity√(2 × 12,000 × 150 ÷ 4)949 units
Orders per year12,000 ÷ 94912.6
Daily demand12,000 ÷ 36033.3
Reorder point33.3 × 7 + 60293 units

Inventory indicators

Indicator Formula Example
Inventory turnover Cost of goods sold ÷ average inventory 2,400 ÷ 200 = 12 times
Average days in stock 360 ÷ inventory turnover 360 ÷ 12 = 30 days
Order fill rate Orders shipped complete ÷ total orders × 100 950 ÷ 1,000 × 100 = 95%

If cost of goods sold is not known, net sales can also be used for turnover. Do not confuse the order fill rate with the line fill rate or unit fill rate; an order with a single short line does not count as complete.

Dwell time

Dwell time is the time a unit of cargo (a pallet, carton, container or railcar) spends in a facility between entering and leaving it. The logic is the same everywhere, but the moment the clock starts and stops depends on the facility:

Where? Clock starts Clock stops Note
Warehouse, distribution centre Goods receipt Dispatch The unit-level counterpart of days in stock
Cross-dock Receiving dock Shipping dock Goods are stored briefly or not at all, so the target is far shorter than in a storage warehouse
Container terminal (import) Discharge from the vessel Exit through the terminal gate The World Bank's port studies measure this interval
Rail terminal Railcar arrives at the terminal Railcar leaves In the US, Class I railroads report terminal dwell as a weekly average in hours

How long can it get? According to a World Bank study published in 2012, average container dwell time was close to 20 days in most sub-Saharan African ports (excluding Durban and Mombasa), against close to 4 days in most large ports in East Asia and Europe. The study shows that most of the delay comes not from handling but from waiting for transactions to be completed and from storage; handling and operations generally add no more than two days.

Do not confuse the two: The Container Port Performance Index (CPPI) of the World Bank and S&P Global measures the time ships spend in port. How long a container or its cargo waits in the terminal is a separate measure.

How to measure it

For a single unit: Dwell time = exit time − entry time. If the WMS or terminal system records an entry and exit timestamp for every unit, the average dwell time is the average of those times.

For an average, Little's law: Without unit-level records, the average can be worked out from average stock and the outflow rate. Little's law says that in a stable system, average stock equals the average arrival (or departure) rate multiplied by the average time in the system:

Average stock = average daily outflow × average dwell time

Average dwell time = average stock ÷ average daily outflow

Little and Graves (MIT) also give an example applying the law to inventory billing in a 3PL warehouse. For the law to hold, stock at the start and end of the period should be roughly the same, and every unit that enters should eventually leave. Use the same unit for stock and outflow: pallets with pallets per day, units with units per day.

Example: A warehouse holds an average of 1,200 pallets and ships an average of 80 pallets a day.

Step Calculation Result
Average dwell time 1,200 ÷ 80 15 days
Annual turns in the same warehouse (360 days) 360 ÷ 15 24 times

How it ties in with the inventory indicators: "Average days in stock" in the table above is the same logic expressed in value. With average inventory of 200 and annual cost of goods sold of 2,400, daily outflow is 2,400 ÷ 360 ≈ 6.67 and dwell time is 200 ÷ (2,400 ÷ 360) = 30 days, the same as 360 ÷ 12 = 30 days. Value-based and pallet-based figures can differ: if expensive items move fast and cheap items move slowly, the two averages drift apart.

Why it matters

  • Capacity: The shorter the dwell time, the more cargo the same space can handle. By Little's law, if dwell time halves while average stock stays the same, twice as much cargo can leave each day. As the World Bank report notes, dwell time is one of the main variables in terminal yard capacity calculations.
  • Cost: Storage charges usually run per day. Once free time ends, every day goes on the invoice. For containers, the terminal operator's storage charge and the carrier's demurrage can run over the same days; for the difference, see Demurrage, detention and storage.
  • Shelf life: For products with an expiry date, a long dwell cuts the shelf life left for the buyer. That is why FEFO matters.
  • Port congestion: The World Bank study shows that long free time and cheap storage push importers to use the port as a warehouse. In Lomé, for example, 21 days of free time for transit cargo significantly increased dwell time.

The customs clock is separate. Under Article 46 of Türkiye's Customs Law No. 4458, a customs-approved treatment or use must be assigned within 45 days of the summary declaration for goods arriving by sea and within 20 days for goods arriving by other means. This is not the same as the free days in a terminal's storage tariff. For official purposes, check the current text on mevzuat.gov.tr.

How chargeable days are counted

Day counting depends on the tariff: some count calendar days, others charge "per day or fraction". The start point varies too; one Turkish container terminal's 2026 tariff, for example, counts import storage days from the day vessel operations begin. The example and calculator in this section use one assumption: 24-hour blocks are counted from entry, and every block started counts as a full day. Always check the rule in your own tariff.

Example: An import container enters the terminal (is discharged) at 08:00 on 2 March and leaves at 14:30 on 9 March. Free time is 5 days and the daily storage rate is 40 (in the tariff's currency).

Step Calculation Result
Dwell time 9 March 14:30 − 2 March 08:00 174.5 hours = 7 days 6 hours 30 minutes (≈ 7.27 days)
Billed days 174.5 ÷ 24 = 7.27 → a started block counts as a full day 8 days
Chargeable days 8 − 5 3 days
Total storage 3 × 40 120

Enter the entry and exit times of a single shipment, the free time and the daily rate to see the dwell time, chargeable days and total cost. In the second part, work out the average dwell time from average stock and daily outflow.

Single shipment
Average (whole warehouse)

Assumption: 24-hour periods are counted from entry and each started period counts as a full day; free time starts at entry. Actual practice depends on the warehouse contract or terminal tariff. The average uses Little's law and assumes a system in balance. The values are examples.

Worked example step by step
StepCalculationResult
Dwell time2026-03-09 14:30 − 2026-03-02 08:00174.5 hours = 7.27 days
Billed dayseach started day counts in full8
Chargeable days8 − 53
Storage cost3 × 40120
Average dwell time1,200 ÷ 8015.0 days

The calculator uses a single daily rate. For tiered tariffs (lower rates for the first days, higher later) and for demurrage, use the calculator in the demurrage topic.

How to shorten dwell time

  • Prepare documents before the cargo arrives. Article 7.1 of the WTO Trade Facilitation Agreement asks members to allow import documents to be lodged and processed before the goods arrive. The World Bank finding points the same way: most of the delay sits on the transaction side.
  • Use an appointment (slot) system. Truck appointment systems at terminal gates have been studied as one of the most workable ways to reduce gate congestion and truck waiting costs. In a warehouse, dock appointments spread receiving and dispatch across the day.
  • Cross-dock where the flow fits. Fast-moving goods with known orders can go straight to outbound without being put away.
  • Measure it and make it visible. Record every unit's entry and exit time in the WMS and track dwell time by customer, product group and site. On the customs side, Article 7.6 of the WTO agreement encourages members to measure and publish average release times with tools such as the World Customs Organization's Time Release Study.
  • Use free time deliberately. Free time is an allowance, not a target. Leaving collection to the last free day means a small delay starts storage and demurrage at the same time.

Test yourself

  1. Which type is the public customs warehouse operated by the customs administration? (Answer: Type F.)
  2. With annual demand of 8,000 units, a cost per order of 100 and an annual holding cost per unit of 4, what is the economic order quantity? (Answer: √(2 × 8,000 × 100 ÷ 4) = √400,000 ≈ 632 units.)
  3. Which picking method should be used for a product with an expiry date? (Answer: FEFO. The item with the nearest expiry date ships first.)
  4. A warehouse holds an average of 500 pallets and ships an average of 25 pallets a day. What is the average dwell time? (Answer: By Little's law, 500 ÷ 25 = 20 days.)

Frequently asked questions

What is the difference between a customs warehouse and a temporary storage facility?

A temporary storage facility is a shed, warehouse or hangar where vehicles stop or unload, in which goods presented to customs and not yet placed under a procedure wait. A customs warehouse is a place for goods under customs supervision; according to Türkiye's Ministry of Trade, goods placed there in line with the rules can stay without a time limit and without paying duties for that period.

What is the difference between FIFO and FEFO?

Under FIFO, the first item stored is the first shipped. Under FEFO, the item with the nearest expiry date is shipped first, which reduces waste and leaves the end user enough shelf life. FEFO is required for products with an expiry date in some rules, such as the EU Good Distribution Practice guidelines for medicinal products.

How is the economic order quantity (EOQ) calculated?

Q* = √(2DS/H), where D is annual demand, S is the cost per order and H is the annual holding cost per unit. For example, with annual demand of 12,000 units, an order cost of 150 and a holding cost of 4, Q* = √900,000 ≈ 949 units. The model rests on assumptions such as constant demand and no stockouts; treat the result as a starting point.

How is safety stock calculated?

The common formula is safety stock = z × σ, where σ is the standard deviation of demand over the lead time and z is the factor for the target cycle service level (about 1.65 for 95%). The reorder point is expected demand over the lead time plus safety stock.

What is dwell time and how is it calculated?

Dwell time is the time a pallet, carton or container spends in a warehouse or terminal between entering and leaving it. For a single unit, subtract the entry time from the exit time. For an average, use Little's law: average dwell time = average stock ÷ average daily outflow. For example, with average stock of 1,200 pallets and 80 pallets shipped a day, the average dwell time is 15 days.

Terms in this topic

Sources

How to cite: Özgür Konakcı, “Warehousing and inventory management”, Logistics Guide, ozgurkonakci.com, 11 November 2026. https://ozgurkonakci.com/en/guide/warehousing-inventory-management/

This guide is for educational purposes and reflects the author's personal views, not those of any current or former employer. For contract, customs and finance decisions, consult current official sources and specialists. Incoterms® is a registered trademark of the International Chamber of Commerce (ICC).