# Shipping by weight (/docs/reference/shipping-weight)

A shipping method priced by weight charges by the total weight of the physical items in the order. Set it up in the dashboard under **Store > Shipping Methods**, or with `weight_config` in [Create a shipping method](/api/shipping-methods/create-shipping-method).

Each product needs a `weight` (an `amount` and a `unit`), set on the product in the dashboard or with [Update a product](/api/products/update-product). A product with no weight adds nothing.

## How the price is worked out [#how-the-price-is-worked-out]

1. Comecero adds up the weight of every **physical** item: its product weight times its quantity.
2. If that weight falls in one of your ranges (`rules`), the price is that range's flat price.
3. Otherwise the price is the **price per weight unit** (`prices_per_unit`) times the weight, in the method's `unit`.

With no ranges, the price is always the price per unit times the weight.

```json
{
  "description": "Ground",
  "countries": ["US"],
  "weight_config": {
    "unit": "lb",
    "prices_per_unit": [{ "price": 2, "currency": "USD" }],
    "rules": [
      { "minimum": 0, "maximum": 5, "unit": "lb", "prices": [{ "price": 10, "currency": "USD" }] },
      { "minimum": 5.01, "maximum": 10, "unit": "lb", "prices": [{ "price": 20, "currency": "USD" }] }
    ]
  }
}
```

| Total weight | Price | Why |
|---|---|---|
| 3 lb | $10 | In the 0 to 5 lb range |
| 8 lb | $20 | In the 5.01 to 10 lb range |
| 11 lb | $22 | In no range: $2 x 11 |

## Units [#units]

Units are `oz`, `lb`, `g` and `kg`. Product weights, ranges and the price per unit do not need to use the same unit: Comecero converts them. Ranges are stored in grams, so they come back with `unit: g`.

## Ranges [#ranges]

- Ranges must not overlap. List them from lowest to highest. When saved, the lowest range starts at 0 and a gap is closed by moving the next range's `minimum` to the previous `maximum` plus 0.01.
- Add as many ranges as you need.

## Currencies [#currencies]

Give the price per unit, and each range's price, in one or more currencies. Each currency may appear once in a list. When the shopper pays in a currency you gave, that price is used. Otherwise the first price in the list is converted to the shopper's currency with your pricing settings' exchange rates and rounding.

After the price is found, any [adjustment](/docs/reference/shipping-adjustments) for the shopper's state or province is applied, then tax and shipping promotions.
