# Production & Non Production Cost

Production and Non-Production cost segmentation allows you to clearly separate business-critical workloads from development, testing, and staging environments.

While this feature is powered by the same backend engine as **Business Hierarchy**, it provides a simplified and standardized way to classify workloads based on environment.

This ensures:

* Clean executive reporting
* Better budget planning
* Accurate savings tracking
* Clear production accountability

***

### Why Environment Segregation Matters

Without clear environment classification:

* Production and test workloads get mixed
* Optimization opportunities are unclear
* Savings tracking becomes distorted
* Finance cannot distinguish operational vs experimental spend

Separating production from non-production enables:

* Accurate margin analysis
* Smarter optimization decisions
* Reduced risk during cost-cutting
* Better forecasting

***

### How It Works

Production & Non-Production classification uses **tag-based rule definitions**.

You define what qualifies as:

* Production
* Non-Production

Based on:

* Tag Key / Value
* Account
* Resource Name
* Service
* Region

The system then categorizes all workloads accordingly.

***

#### Example Classification Logic

If:

* Tag `environment = prod`
* OR Tag `env = production`
* OR Account name contains `live`

Then:

→ Classify as **Production**

If:

* Tag `environment = dev`
* OR Tag `env = staging`
* OR Resource name contains `test`

Then:

→ Classify as **Non-Production**

***

<figure><img src="/files/IFG6fgjqA6NAy1UEakGF" alt=""><figcaption></figcaption></figure>

***

### Supported Rule Conditions

You can define rules using:

* Native Cloud Tags
* Account Name
* Subscription Name
* Project ID
* Resource Name
* Service
* Region
* Usage Type

Rules follow AND logic within a rule block.

Multiple rule blocks can be defined.

***

### How It Is Different from Business Hierarchy

| Feature          | Business Hierarchy              | Production & Non-Production              |
| ---------------- | ------------------------------- | ---------------------------------------- |
| Purpose          | Maps cost to business ownership | Segregates cost by environment type      |
| Depth            | Up to 4 levels                  | Binary classification (Prod vs Non-Prod) |
| Resource Mapping | Leaf-level cost centre          | Rule-based environment grouping          |
| Use Case         | BU / Team / Project reporting   | Operational environment reporting        |

Internally, both use the same allocation engine.\
Production & Non-Production is simply a simplified, purpose-built segmentation layer.

***

### Reporting Capabilities

Once configured, you can:

* View total Production spend
* View total Non-Production spend
* Compare Prod vs Non-Prod trends
* Filter dashboards by environment
* Track savings by environment type
* Monitor policy violations separately

***

### Best Practices

To ensure accurate classification:

* Standardize environment tag keys across teams
* Avoid multiple meanings for the same tag
* Review unmatched resources monthly
* Align environment definition with engineering policy

Recommended tag keys:

* `environment`
* `env`
* `stage`
* `deployment`

***

### Common Multi-Cloud Examples

#### AWS

* `environment = prod`
* `aws:autoscaling:groupName contains live`
* Account name contains `production`

#### Azure

* `Environment = Production`
* Subscription name contains `Prod`
* Resource group contains `Live`

#### GCP

* Label `env = prod`
* Project ID contains `production`

#### OCI

* Tag namespace `Operations.Environment = Prod`

***

### Why This Feature Is Important

Production workloads:

* Directly impact revenue
* Require higher reliability
* Must be optimized carefully

Non-production workloads:

* Can be aggressively optimized
* Can tolerate scheduling policies
* Are ideal for automation-based savings

This separation enables smarter FinOps decisions.

***

### Governance Alignment

Environment classification also enables:

* Production-only alerting
* Non-production shutdown policies
* Environment-specific workflow automation
* Scoped access controls

If you have not configured cost centres yet, refer to:

👉 **Cost Centres & Business Hierarchy**

***

### Summary

Production & Non-Production Cost gives you:

* Clean workload segregation
* Accurate financial visibility
* Better optimization control
* Executive-level clarity

It is simple to configure, but powerful in impact.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.onelens.cloud/observe-visibility-and-insights/cost-allocation/production-and-non-production-cost.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
