To calculate shipping costs when selling online, work out the chargeable weight of each order, apply the rate from your carrier quote, then add the base fee, fuel surcharge and tax. Then decide how much of that cost the customer pays: the exact amount at checkout, a flat rate, or free shipping above an order value you set. The arithmetic is the same for every order, but the charging rule decides whether shipping supports your margin or erodes it.
Use our free shipping cost calculator to check a typical order before you set a rule in your store. It handles several packages at once, shows actual and volumetric weight side by side, and lists every step of the total. This guide covers the inputs, the charging models, the margin check and the mistakes that most often cost online sellers money. You can also see our other free tools.
Why online shipping needs a rule, not a guess
An online shop sends many small orders, and each one has its own weight, size and destination. Estimating shipping by feel can work for a few orders a week, but it breaks down as volumes grow. A rule that you calculate once, test and review gives you a number you can explain to customers and to your accountant.
Shipping sits between the product and the customer, so it affects conversion as well as cost. A charge that appears late in checkout can make a customer leave the basket, so the rule is also a sales decision.
The inputs you need for each order
Every shipping figure starts from a few inputs. If one of them is wrong, the total will be wrong too, and the error repeats on every order that uses the same box or destination.
| Input | What to record | Common error |
|---|---|---|
| Packed weight | Weight of the parcel with its packaging, from a checked scale | Weighing the product alone |
| Outside dimensions | Length, width and height of the box, in one unit | Mixing centimetres with inches |
| Divisor | The volumetric divisor stated in your service terms | Using an old divisor from a previous contract |
| Destination and service | The country and service level the order travels by | Applying one domestic rate to international orders |
| Surcharges and tax | Fuel surcharge percentage, tax percentage and base fee | Leaving them out of the estimate |
Step 1: gather the same inputs for your orders
Start with orders you have already shipped. Choose a sample of ten to twenty orders that cover your most common box sizes and destinations. Record the packed weight and outside size of each parcel, and note the service each order used. The sample shows which parcels are charged on volume and which on actual weight.
- Pick the boxes you use most often and weigh a packed example of each.
- Measure the outside of each box and write every dimension in the same unit.
- Note the destination and the service that each order used.
- Store the figures in one place, such as a shared sheet or your ERP record, so the next person works from the same data. For how stock records are usually structured, see our guide to inventory management methods.
Step 2: calculate the chargeable weight of each order
For each parcel, compare the actual weight with the volumetric weight. Multiply the three outside dimensions, divide the result by your divisor, and keep the higher of the two figures. The shipping cost calculator does this for each row, so you can enter the sample and check every result.
For example, a 40 × 30 × 25 cm box with a packed weight of 5 kg has a volume of 30,000 cm³. With a divisor of 5,000 its volumetric weight is 6.0 kg, so the chargeable weight is 6.0 kg. A 35 × 25 × 20 cm box with the same 5 kg packed weight has a volumetric weight of only 3.5 kg, so it is charged at 5.0 kg on actual weight.
Step 3: add the rate, base fee and surcharges
Turn the chargeable weight into a cost with the same four steps for every order.
- Multiply the chargeable weight by the rate per weight unit from your quote.
- Add the base fee once per shipment.
- Add the fuel surcharge as a percentage, applied in the way your quote states.
- Add tax last, using the rate that applies to the sale.
Run the sum for each common order type and keep the results in a table. For instance, 6.0 kg at an example rate of 10.00 per kilogram gives 60.00, and with a base fee of 2.00 the subtotal is 62.00 before fuel surcharge and tax. Replace the example figures with your own quote before you rely on any result.
Step 4: choose a shipping charging model
Once you know the cost of a typical order, decide what the customer pays. Four models are common, and each suits a different kind of shop.
| Model | How it works | Suits | Main risk |
|---|---|---|---|
| Exact cost at checkout | The customer pays the calculated charge for their own order | Heavy or bulky items sent to varied destinations | Checkout can feel expensive when the charge comes as a surprise |
| Flat rate | One fixed charge per order, or one per zone | Shops whose parcels are similar in size | Light orders pay more than they cost, while heavy ones pay less |
| Free shipping above a value | Shipping is free once the basket reaches an amount you set | Shops that want larger baskets | The threshold sits below the cost of a typical order |
| Shipping built into the product | The product includes postage, and the shop shows shipping as free | Shops with one product type and a stable cost | Rate changes are harder to absorb when the cost is hidden in the product |
Whichever model you choose, write the rule in plain words in your store, for example "Shipping is calculated at checkout, and orders above the threshold ship free." Plain rules reduce returns and support questions.
Step 5: test the rule against your margin
A shipping rule can look fair and still take the profit out of a sale. Use our profit margin calculator to enter the product cost, the sale amount and the postage, and see what remains. Repeat the check for your smallest order, because a low-value product with a fixed base fee leaves the least room for postage.
Step 6: review the rule every month
- Compare the estimated cost of ten recent orders with their invoices.
- Check whether any service, destination or divisor has changed in your terms.
- Look at the orders that shipped free and confirm that the threshold still covers their cost.
- Update the rule or the rate table, and record the date of the change.
Keep orders, stock and shipping data together
Shipping costs are easier to check when order data, stock levels and logistics information sit in one system. Dika Ops runs orders, inventory and logistics on one record and syncs stock with online stores such as Shopify, so the figures your shipping rule depends on do not have to live in separate spreadsheets. For how a shop connects to its back office, see our Shopify ERP integration guide.
When a shop needs its own commerce rules, our enterprise web and digital commerce work covers the setup, and you can talk to us about what fits your business. Our team at Dika Design is happy to look at your order data with you.
Frequently asked questions
Should I charge customers the exact shipping cost?
Not always. Charging the exact cost at checkout is the most transparent option, but it can make the basket feel expensive. Many sellers use a flat rate or a free-shipping threshold for simple, predictable orders, and check each choice against their margin.
Is a flat rate or calculated shipping better?
Calculated shipping suits varied parcel sizes and destinations. A flat rate suits shops whose parcels are similar. Test both on your sample orders, and choose the option where the gap between the charge and the cost is smallest.
How do I stop shipping costs eating my margin?
Use the smallest suitable box, calculate the chargeable weight rather than relying on the scale alone, and set any free-shipping threshold above the cost of a typical order. Review the rule each month against real invoices.
Do shipping costs differ by country?
Yes. The destination and the service level change the rate, and tax rules vary between countries. Calculate international orders separately, using the rate and tax that apply to each destination in your terms.
Can shipping costs be calculated automatically in an online shop?
Often, yes, through the shipping settings of the shop platform or an integrated system. Whether the calculation runs automatically depends on your platform and your service. Test one order from start to finish before you rely on the automation.
Summary
To calculate shipping costs when selling online, measure each parcel, work out its chargeable weight, add the rate, base fee, surcharge and tax, and choose a charging model you can review. Test the rule against your margin and check it against invoices every month. The shipping cost calculator performs the arithmetic and shows its working, so you can explain every figure.



