If you’ve ever opened an invoice from a shipping line and found a demurrage charge you didn’t expect, you’re not alone. Demurrage is one of the most common — and most avoidable — costs in international trade. Most importers and exporters don’t get hit with it because their cargo is late. They get hit with it because nobody on their team actually knew how the charge was calculated until it was too late to do anything about it.
This guide breaks down exactly how demurrage is calculated, walks through real number examples, and shows you where the free time clock actually starts (it’s usually not where people think). By the end, you’ll be able to check a demurrage invoice yourself instead of taking the carrier’s word for it.
What Is Demurrage in Shipping?
Demurrage is a fee charged by a shipping line or terminal when a container sits at the port longer than the agreed “free time” period — either before it’s loaded onto a vessel (export) or after it’s discharged and before it’s picked up (import).
Think of it as a parking fine for containers. The shipping line owns a limited pool of boxes and needs them moving to keep the supply chain flowing. When your container overstays its welcome at the terminal, the line charges you daily for the delay.
It’s important to separate this from a related but different charge: detention. We’ll cover that distinction in detail below, because mixing the two up is one of the most expensive mistakes shippers make.
How Demurrage Charges Are Calculated: The Core Formula
At its simplest, the demurrage calculation formula looks like this:
Demurrage Charge = Number of Days Beyond Free Time × Daily Demurrage Rate
But that one-line formula hides three variables that actually determine your final bill:
- Free time allowance — how many days you get before charges start
- Chargeable days — which calendar days actually count
- Rate structure — whether the daily rate is flat or tiered (increases the longer the container sits)
Let’s unpack each one, because this is where most disputes happen.
1. Free Time: Where the Clock Actually Starts
Free time is the number of days a shipping line gives you to move a container before demurrage kicks in. It typically ranges from 3 to 7 calendar days, though this varies by carrier, trade lane, and negotiated contract terms.
For import containers, the clock usually starts the day the vessel is discharged at the port (not the day you receive the arrival notice, and not the day customs clears the cargo).
For export containers, free time typically starts when the empty container is picked up from the depot, running until the container is gated in at the terminal for loading.
Expert tip: Always confirm free time in writing on the booking confirmation or bill of lading, not verbally with a sales rep. Free time terms can vary even between shipments with the same carrier, especially if you’re operating under a negotiated service contract versus the carrier’s public tariff.
2. Counting Chargeable Days Correctly
This is where a lot of manual calculation errors happen. Some carriers count calendar days including weekends and holidays; others exclude non-working port days. Some start counting from day zero, others from day one.
Worked example — Import container:
| Detail | Value |
| Vessel discharge date | June 1 |
| Free time allowed | 5 days |
| Free time expires | June 6 |
| Container gated out | June 10 |
| Chargeable demurrage days | 4 days |
| Daily demurrage rate | $150/day |
| Total demurrage charge | $600 |
The math itself is simple. The part that trips people up is correctly identifying when free time actually expired and whether the carrier’s tariff counts inclusively or exclusively of the discharge date.
3. Tiered Demurrage Rates
Many carriers don’t charge a flat daily rate. Instead, they use a tiered structure that increases the longer your container sits, designed to discourage prolonged delays.
Example tiered rate structure:
| Days Beyond Free Time | Daily Rate |
| Days 1–5 | $150/day |
| Days 6–10 | $250/day |
| Days 11+ | $400/day |
Worked example using tiered rates (10 days late):
- Days 1–5 (5 days × $150) = $750
- Days 6–10 (5 days × $250) = $1,250
- Total demurrage = $2,000
Notice how this is significantly higher than a flat-rate calculation (10 × $150 = $1,500 flat). This is exactly why understanding your carrier’s specific rate tariff matters — assuming a flat rate when the structure is tiered can throw your cost forecasting off by 30% or more on longer delays.
Demurrage vs. Detention: Why the Difference Matters for Your Calculation
This is the single most misunderstood distinction in container shipping, and it changes what formula applies to your situation.
| Demurrage | Detention | |
| What it covers | Container sitting at the port/terminal | Container sitting outside the port (at your warehouse or depot) |
| Applies to | Time before loading (export) or after discharge, before gate-out (import) | Time after gate-out until the empty container is returned |
| Who controls the delay | Port congestion, customs holds, terminal capacity | Your unpacking, trucking, or inland logistics speed |
| Typical trigger | Container still occupying terminal yard space | Container off-terminal, not yet returned empty |
Many carriers now issue a combined demurrage and detention charge on a single invoice, especially in congested markets. Always ask your carrier to itemize the two separately — combined invoices make it much harder to identify which part of your supply chain caused the delay, and therefore which team needs to fix the process.
Step-by-Step: How to Calculate Your Own Demurrage Exposure
Follow this process before a shipment even arrives, not after you get the invoice.
Step 1: Confirm the Free Time Terms in Your Contract or Booking
Check the bill of lading, service contract, or carrier tariff for the exact number of free days and how the countdown is defined (calendar vs. working days).
Step 2: Identify the Trigger Date
- Import: vessel discharge date (found on the terminal’s tracking portal)
- Export: empty container pickup date
Step 3: Track the Realistic Gate-Out or Gate-In Date
Factor in customs clearance time, trucking availability, and terminal appointment slots — not just the “ideal” timeline.
Step 4: Apply the Rate Tariff
Pull the exact daily rate (flat or tiered) from your carrier agreement. Don’t estimate — rates vary widely by carrier, port, and even season.
Step 5: Calculate Days at Risk vs. Free Time
Days at Risk = Estimated Gate-Out Date − Free Time Expiry Date
If this number is positive, you have exposure. Multiply by the applicable rate tier(s).
Expert tip: Build this calculation into your shipment tracking spreadsheet or TMS as a standard column, not a reactive exercise. Freight teams that calculate demurrage risk proactively, before free time expires, typically catch and resolve delays 2–3 days earlier than teams that only look at it after receiving an invoice.
Common Mistakes When Calculating Demurrage
- Confusing calendar days with working days. Some ports exclude Sundays or public holidays from the countdown; assuming otherwise leads to disputed invoices.
- Using the arrival notice date instead of the actual discharge date. These are often different by a day or more.
- Forgetting per diem vs. tiered structures. Applying a flat rate to a tiered contract underestimates your exposure significantly on longer delays.
- Not separating demurrage from detention on combined invoices. This hides which part of the process is actually causing cost.
- Ignoring holidays and weekends at the destination port. A container arriving before a long public holiday can burn through free time before your team is even back in the office.
- Overlooking per-container vs. per-shipment terms. On multi-container shipments, demurrage is almost always calculated per container, not per bill of lading — a mistake here can multiply your estimate error.
How to Avoid Demurrage Charges
Reducing demurrage isn’t about faster paperwork alone — it’s about removing the specific bottlenecks that eat into free time.
- Pre-clear customs before vessel arrival. Submit documentation as soon as the vessel departs origin, not after it arrives.
- Book trucking capacity in advance. In congested markets, trucking availability — not customs — is often the real bottleneck.
- Negotiate longer free time on high-volume lanes. Carriers are often willing to extend free time by 2–3 days for shippers with consistent volume.
- Use a container tracking tool or carrier portal. Real-time discharge and last-free-day alerts give your team a buffer to react.
- Consider off-dock storage for known delays. Moving a container off-terminal quickly and paying detention (often cheaper than terminal demurrage) can reduce total cost when a delay is unavoidable.
- Request a Letter of Indemnity or extension from the carrier proactively if a documented delay (customs hold, strike, weather) is outside your control — some carriers waive charges in genuine force majeure situations.
Pros and Cons of Common Demurrage Mitigation Strategies
| Strategy | Pros | Cons |
| Off-dock container storage | Avoids escalating terminal rates | Adds trucking and storage cost elsewhere |
| Negotiated extended free time | Reduces exposure on every shipment | Requires volume leverage to negotiate |
| Real-time tracking software | Early warning reduces missed deadlines | Requires setup and carrier data integration |
| Carrier waiver requests | Can eliminate charges for valid delays | Not guaranteed; carrier discretion applies |
Demurrage Calculator: What a Good One Should Include
If you’re building or evaluating a demurrage calculator (spreadsheet or software), make sure it accounts for:
- Free time start date logic (discharge vs. pickup, per direction)
- Calendar vs. working day counting rules
- Flat vs. tiered rate structures
- Per-container calculation (not per-shipment)
- Separate detention tracking
- Port-specific holiday calendars
A calculator missing any of these will systematically under- or over-estimate your real exposure.
FAQs About Demurrage Calculation
How is demurrage calculated in shipping?
Demurrage is calculated by multiplying the number of days a container exceeds its free time allowance by the carrier’s daily demurrage rate, which may be flat or tiered depending on the contract.
What is free time in container shipping?
Free time is the number of days — usually 3 to 7 — that a shipping line allows before demurrage charges begin, starting from vessel discharge (imports) or container pickup (exports).
What’s the difference between demurrage and detention?
Demurrage applies while a container is at the port or terminal; detention applies once the container has left the terminal and is awaiting return to the depot, empty.
Who pays demurrage charges, the importer or exporter?
This depends on the shipping terms (Incoterms) and who is named as the consignee or responsible party on the bill of lading — typically whoever controls the container’s movement at the point of delay.
Can demurrage charges be disputed or waived?
Yes. If the delay was caused by carrier error, terminal congestion outside your control, or a documented force majeure event, many carriers will consider a waiver request, particularly for shippers with an ongoing relationship.
Do demurrage rates vary by port or carrier?
Yes, significantly. Rates depend on the carrier’s tariff, the specific port’s congestion levels, and whether you’re operating under a public tariff or a negotiated service contract.
Is demurrage charged per container or per shipment?
Per container. A shipment with five containers that each individually exceed free time will generate five separate demurrage calculations.
Conclusion: Key Takeaways for Managing Demurrage Costs
Demurrage doesn’t have to be a surprise line item. The charge itself is just simple multiplication — days over free time times the daily rate — but getting an accurate number depends on knowing your specific free time terms, correctly identifying the trigger date, and applying the right rate structure.
Actionable next steps:
- Pull your current carrier contract and confirm exactly how free time is defined for your major trade lanes.
- Build a simple tracking column into your shipment spreadsheet or TMS that flags the last free day per container.
- Separate demurrage and detention on every invoice you receive going forward.
- Revisit your free time terms annually — they’re often negotiable if your volume has grown since your last contract renewal.
Getting ahead of demurrage isn’t about eliminating delays entirely; ports and customs will always introduce some unpredictability. It’s about knowing your numbers well enough that when a delay happens, you can calculate the cost impact immediately and make an informed decision — rather than finding out what it cost you a month later on an invoice.