EnableYourData.com

KPI · Logistics

Shipping cost as % of sales: formula and example.

Shipping cost as a percentage of sales shows what share of revenue you spend on carriers. It makes shipping costs comparable between months with different revenue and between channels. It is a direct indicator of how much logistics weighs on your margin.

Shipping cost as % of sales formula

Total shipping cost ÷ revenue × 100%

Worked example

In May 2026 Acme Groothandel paid €27,200 in shipping costs on revenue of €680,000. Shipping cost as a percentage of sales is €27,200 ÷ €680,000 × 100% = 4.0%.

Fictitious figures for Acme Groothandel, a sample wholesaler.

How to read this KPI

A lower percentage means transport eats less of your margin. The ratio falls on its own when average order value rises, even if the cost per parcel stays the same. Compare by channel and country, with your own gross margin and with what customers pay you for delivery.

Pitfalls with shipping cost as % of sales

  • Using revenue including VAT while shipping costs exclude it.
  • Including shipping charged to customers in revenue without showing it separately, so the net effect stays hidden.
  • Booking shipping on dispatch date and revenue on order date without allowing for the month-end gap.

SQL & DAX

Calculating shipping cost as % of sales in SQL and DAX

Two examples on a fictitious data warehouse for Acme Groothandel: a PostgreSQL query and a measure for a Power BI model. Adjust table and column names to your own model.

SQL · PostgreSQL
WITH cost AS (
  SELECT date_trunc('month', shipped_at) AS month, SUM(cost) AS shipping_cost
  FROM shipments
  GROUP BY 1
),
revenue AS (
  SELECT date_trunc('month', order_date) AS month,
         SUM(total_amount) AS revenue,
         SUM(shipping_cost) AS shipping_charged
  FROM orders
  GROUP BY 1
)
SELECT r.month, c.shipping_cost, r.shipping_charged, r.revenue,
       ROUND(100.0 * c.shipping_cost / NULLIF(r.revenue, 0), 2) AS shipping_cost_ratio_pct
FROM revenue r
LEFT JOIN cost c ON c.month = r.month
ORDER BY r.month;
DAX · Power BI
Shipping Cost Ratio = DIVIDE(SUM(Shipments[Cost]), SUM(Orders[TotalAmount]))
Net Shipping Cost Ratio = DIVIDE(SUM(Shipments[Cost]) - SUM(Orders[ShippingCost]), SUM(Orders[TotalAmount]))

In ENABLE

Tracking this KPI in ENABLE

Plain-language questions

Ask for shipping cost as % of sales per month, customer or product in the SQL Explorer with AI. The AI writes the SQL, you see the query and run it yourself; the AI only receives metadata.

Read more →

In your Power BI dashboard

Define the KPI as a measure in your Power BI model and show it in the portal, with "Last refreshed" next to it. Access profiles and optional row-level security decide who sees which figures.

Read more →

Custom dashboards (pilot)

Add the KPI as a tile to a custom dashboard, compared with last year. The Dashboard Builder is a pilot and can be switched on per client.

Read more →

Monthly targets

With the built-in Targets app you set a target for the KPI per month, so you see actuals and target side by side.

Read more →

FAQ

Frequently asked questions

How do you calculate shipping cost as a percentage of sales?

Divide total shipping cost for a period by revenue for the same period and multiply by 100. Use amounts excluding VAT for both. Show shipping charged to customers separately so you can also see the net effect.

Why does the ratio fall when my orders get bigger?

The cost of a parcel usually rises more slowly than the value of what is inside. A larger order spreads the same shipping cost over more revenue. That is why it is best to look at this ratio together with shipping cost per order.

How is this different from shipping cost per order?

Shipping cost per order is an amount in euros, whereas this ratio sets that cost against revenue. The amount tells you about rates and efficiency, the ratio about the impact on margin. A rising amount can be fine if order value rises faster.

Use AI on your own data. Securely, and without the headache.

In an online demo we show how ENABLE makes your data securely available and how you build on it: describing an app in the AI Builder, plain-language questions, dashboards and APIs. And how we set it up and manage it for you.