Demurrage and Detention Cost Calculator for Ocean Containers
Demurrage and detention are the per diem charges carriers bill when a container stays too long at the terminal or outside it. This calculator lets you test free days, tier breakpoints and clearance delay so you can see what a late release really costs.
Your numbers
Calendar days from discharge to gate out, unless the tariff counts working days.
From gate out to empty return.
Your results
Illustrative tiers only. Use the actual tariff or service contract of your ocean carrier, which sets free time, tier breakpoints, whether weekends count and the equipment type. Rates are not published here.
Total D&D vs days in terminal
Sweeps Days in terminal after discharge from 0 to 30, holding your other inputs fixed.
Container event tracking review
Optional: we can look at how container dates and carrier invoices reach your ERP and suggest ways to catch D&D earlier.
Optional. The tool and every export work without this. No spam.
Demurrage versus detention
Demurrage is charged for a loaded container sitting inside the port or terminal beyond free time. Detention is charged for equipment held outside the terminal, for example at your warehouse, beyond its free time until the empty is returned. Some carriers combine them into a merged day count. Always check how your contract defines the start and stop events, such as discharge, availability, gate out and empty return.
How to use it
Enter the number of containers, days at the terminal and days held outside, then fill in free days and tier rates from your tariff. The calculator counts only days beyond free time, splits them across the tiers and adds detention. Use the chart to see how fast the total climbs when customs release slips. Escalating tiers mean the tenth day usually costs far more than the fifth.
- Obtain the tariff in writing before arrival
- Confirm whether weekends and holidays count
- Track the start event, not just the vessel ETA
Worked example
Four containers sit 12 days, with 4 free. That leaves 8 chargeable days: 5 in tier 1 at 150 and 3 in tier 2 at 250, which is 1,500 per container. Detention is 8 days out with 5 free, so 3 days at 120, or 360. Per container the cost is 1,860, and for four containers the total is 7,440. Clearing three days earlier would remove the whole tier 2 amount.
Common mistakes
Counting days from the vessel ETA instead of the discharge or availability date, ignoring a free-time extension agreement, and treating detention as optional are frequent errors. Failing to log gate-out and return dates makes disputes hard to win. Record container numbers, dates and invoice references in your ERP or TMS so charges can be matched to cause, and so late-arriving documents are traced to the supplier or broker.
Frequently Asked Questions
Who pays demurrage and detention?
Normally the party named as merchant or consignee in the carrier's bill of lading terms is liable, which can be the importer even when a broker or forwarder causes the delay. Your commercial contract and Incoterm decide who should bear the cost between buyer and seller, so settle that before shipping.
Can demurrage be disputed?
Often, yes. Common grounds are terminal closures, missing carrier release, equipment unavailable for pickup, or free time not applied correctly. Regulators in some countries set billing rules for these charges. Keep timestamps and emails, and raise the dispute with the carrier within the period stated in its tariff.
Do weekends count as free days?
It depends on the tariff. Some carriers count calendar days, others exclude weekends and holidays at the terminal. This tool counts days exactly as you enter them, so convert working days to the day count your contract uses before you enter the figure.
How can I reduce demurrage and detention?
Pre-clear customs before arrival, send documents early, book trucks ahead, negotiate longer free time for the lane, and choose a terminal or drayage partner with return slots. Review lanes that repeatedly exceed free time and fix the root cause, which is often document timing.
If D&D invoices are checked by hand against emails, Netray can help match container events to invoices and flag disputable charges before they are paid.
Related Tools
Bill of Lading Field Checklist
A field-by-field check of an ocean or domestic bill of lading so errors are caught before the cargo sails.
Supply Chain & InventoryIncoterms 2020 Reference Table
Searchable comparison of the 11 Incoterms 2020 rules: where risk passes, who pays carriage, who clears export and import.
Supply Chain & InventoryContainer Loadability CBM Calculator
Estimate cartons per container using carton CBM, packing efficiency and payload so you know whether you cube out or weigh out.
Compliance & ContractsCommercial Invoice Template for Export
Generate a customs-ready commercial invoice with parties, Incoterm, HS code, country of origin and value declaration.
More Supply Chain & Inventory tools
See all- Oracle Fusion Inventory Turns and Carrying Cost Calculator
- Distribution ERP Fill Rate Calculator
- Distributor Rebate Tracking Worksheet
- Branch Transfer Planning Worksheet
- Distributor Slow-Moving Inventory Review Worksheet
- Distributor Vendor Performance Scorecard Worksheet
- Distributor GMROI Calculator
- Distributor Backorder Cost and Fill Rate Calculator
- EOQ with Vendor Minimum Order Calculator