How to Make Tags Show Up in Cost Data on AWS, GCP and Azure
Putting a tag on a resource is step one. Each cloud has a second step before that tag can split a bill, and they are all different.
A tag that exists on a resource but not in billing data is invisible to anyone slicing cost. AWS needs the tag key activated, Google Cloud carries labels into its billing export but you have to query them, and Azure only copies resource group and subscription tags down to usage if you ask it to. Here is the second step on each.
AWS: activate cost allocation tags
Only the management account of an organization (or a standalone account) can manage cost allocation tags.
- Find candidate keys. Newly applied tags can take up to 24 hours to appear.
aws ce list-cost-allocation-tags --status Inactive --type UserDefined- Activate the keys you want in cost data, up to 20 per call:
aws ce update-cost-allocation-tags-status --cost-allocation-tags-status \ TagKey=team,Status=Active TagKey=environment,Status=ActiveActivation itself can take up to another 24 hours. The console equivalent is Billing and Cost Management › Cost allocation tags › Activate.
- Backfill, because activation is otherwise forward-looking. A management account can backfill activation status for up to twelve months, once every 24 hours; the start must be the first day of a month:
aws ce start-cost-allocation-tag-backfill --backfill-from 2025-10-01T00:00:00ZBackfill cannot invent history: months before the tag was on the resource still have no value for it.
- Verify with
aws ce list-cost-allocation-tags --status Active, then group by the tag in Cost Explorer.
Google Cloud: query labels in the billing export
Resource labels flow into the Cloud Billing export to BigQuery as a repeated labels field. Labels must be lowercase letters, digits, underscores and dashes, keys start with a letter, and each resource can hold up to 64. To add one to a VM:
gcloud compute instances add-labels web-1 --zone=us-central1-a --labels=team=checkoutTo split cost by a key without silently dropping unlabeled spend, join on the key rather than filtering with WHERE, as Google’s own example does:
SELECT labels.value AS team, SUM(cost) AS costFROM `billing-project.billing_dataset.gcp_billing_export_v1_XXXXXX_XXXXXX_XXXXXX`LEFT JOIN UNNEST(labels) AS labels ON labels.key = "team"GROUP BY team;The null row is your untagged spend. Do not sum rows across different keys: Google warns that combining key/value groupings double counts.
Azure: enable tag inheritance
Azure resources carry their own tags into usage, but tags set on a resource group or subscription do not reach the resources’ usage records unless tag inheritance is on. It is available for EA, MCA and MPA (Azure plan) billing accounts and needs Cost Management Contributor to change on a subscription.
- Open Cost Management (not Cost Management + Billing) and select the scope.
- Under Settings, select Configuration, then Tag inheritance › Edit.
- Select Automatically apply subscription and resource group tags to new data.
Inherited tags are written onto usage records, not the resources. To tag a resource group itself:
az tag update --resource-id /subscriptions/SUB_ID/resourceGroups/checkout-rg \ --operation Merge --tags team=checkoutCheck the result the same way everywhere
Pick one tag key, one month, and compare the untagged share before and after. If it does not drop, the tag is not on the resources that bill (volumes, snapshots and load balancers are frequent gaps). Naming the keys consistently is covered in tagging strategy.
Tag attribution in ZopNight
ZopNight reads AWS tags, GCP labels and Azure tags directly from the resources, plus accepted smart tags, and attributes cost on the Reports page’s Tags tab. Each key and value pair receives the full cost of every resource that carries it (there is no splitting), each row shows whether the tag came from the cloud or a smart tag, and the dashboard’s Tag Coverage widget shows tagged against untagged spend. Filling gaps without retagging by hand is covered in smart tags policies.