> ## Documentation Index
> Fetch the complete documentation index at: https://docs.upstackdata.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Total Cost: Complete Order Cost Stack

> Track total cost per order including COGS, fulfillment, marketing, and overhead. Understand your complete cost structure.

<Tip>
  Total Cost measures the complete cost stack for your orders, including COGS, fulfillment, marketing costs, agency fees, and operating expenses.
</Tip>

## Formula

<Info>
  **Total Cost** = **COGS** + **Fulfillment** + **Marketing** + **Agency Fees** + **Opex**
</Info>

### Formula Components

| Metric                                                                       | Definition                      |
| ---------------------------------------------------------------------------- | ------------------------------- |
| [**COGS**](/reference/metrics/orders/cogs/cogs)                              | Cost of goods sold for products |
| [**Fulfillment**](/reference/metrics/orders/fulfillment/fulfillment-cost)    | Shipping and handling costs     |
| [**Marketing**](/reference/metrics/orders/performance/total-ad-spend)        | Total advertising spend         |
| [**Agency Fees**](/reference/metrics/orders/contribution-margin/agency-fees) | Marketing agency costs          |
| [**Opex**](/reference/metrics/orders/contribution-margin/opex)               | Operating expenses              |

| Metadata        |                                                                                                                                            |
| --------------- | ------------------------------------------------------------------------------------------------------------------------------------------ |
| **Type**        | Currency                                                                                                                                   |
| **Data Source** | [Shopify](/sources/shopify), [Meta Ads](/sources/facebook-ads), [Google Ads](/sources/google-ads), [Upstack Costs](/sources/upstack-costs) |
| **Aggregation** | Sum                                                                                                                                        |

***

## Example

Your Shopify store incurred the following costs:

| Cost Component | Value        |
| -------------- | ------------ |
| COGS           | \$40,000     |
| Fulfillment    | \$8,000      |
| Marketing      | \$25,000     |
| Agency Fees    | \$5,000      |
| Opex           | \$12,000     |
| **Total Cost** | **\$90,000** |

A total cost of \$90,000 means you need at least \$90K in revenue to break even.

***

## How It Works

Total Cost aggregates all cost categories attributed to your orders. This includes direct product costs (COGS), logistics (fulfillment), customer acquisition (marketing), and operating overhead. It's the complete picture of what it costs to generate your revenue.

***

## When to Use

| Scenario               | Action                            |
| ---------------------- | --------------------------------- |
| Profitability analysis | Compare total cost to revenue     |
| Break-even planning    | Understand minimum revenue needed |
| Cost optimization      | Identify largest cost drivers     |
| Budget allocation      | See where money is being spent    |

***

## Related Metrics

| Metric                                                                                       | Relationship                             |
| -------------------------------------------------------------------------------------------- | ---------------------------------------- |
| [NC Total Cost](/reference/metrics/orders/contribution-margin/new-customer-total-cost)       | Total cost for new customer orders       |
| [RC Total Cost](/reference/metrics/orders/contribution-margin/returning-customer-total-cost) | Total cost for returning customer orders |
| [Net Profit](/reference/metrics/orders/contribution-margin/net-profit)                       | Revenue minus total cost                 |
| [CM3](/reference/metrics/orders/contribution-margin/cm3)                                     | Profit after all variable costs          |

[See all Contribution Margin metrics →](/reference/metrics/orders/contribution-margin)
