- Identification and ownership — Attach
owner: Samto identify the person responsible for a VM. - Environment classification — Use
environment: productionorenvironment: devto separate workloads. - Logical grouping — Group resources for a project across resource groups and subscriptions.
- Cost allocation — Tag with
cost-centerorproject-codeto attribute costs accurately in billing reports.
- Tags are name-value pairs (for example,
department: HR). - Tags can be applied at the subscription, resource group, and resource level.
- Billing and detailed cost reporting are always tied to resources, so resource-level tags matter for cost analysis.
- Tags do not inherit automatically from parent scopes (resource group or subscription) to child resources unless you enforce that with policies or use a preview inheritance feature.
Tags do not inherit by default. If you apply tags only at the resource group or subscription level, those tags are not automatically included in billing or resource-level tag queries. Use policy enforcement (recommended for production) to enforce or copy tags to resources, or enable the preview tag-inheritance feature only after evaluating its readiness for your environment.

Practical implications:
- For cost reporting, ensure tags are actually present on resources (or use Azure Policy to copy tags to resources).
- Azure Policy is the recommended production method to apply or enforce tags automatically.
- Open the Azure portal and go to All resources.
- Select the resource you want to tag (for example, a virtual machine).
- In the resource menu, choose Tags (or click Edit on the Tags blade).
- Add a name-value pair such as
environment: Devorcost-center: 1100, then click Save.

- The portal suggests previously used tag names and values, which helps maintain consistency across resources.
- Use the All resources filter or the Tags view to list resources by tag key/value combinations.

- Open the target resource and open the Tags blade (or click Edit).
- Modify tag values or click the trash icon to remove a tag.
- Click Save. Refresh the resource list if changes do not appear immediately.


- Azure CLI — apply tags to an existing resource (replace names as needed):
- Azure PowerShell — set tags on a resource:
- Standardize tag keys and values with a naming convention (for example,
environmentvalues:dev,test,prod). - Enforce tag rules using Azure Policy (required fields, allowed values, or automatic copying).
- Apply tags at resource creation to ensure early cost attribution.
- Periodically audit tags and remove or consolidate unused tag keys.
- Use consistent casing and separators to avoid duplicates (for example, choose either
CostCenterorcost-center).
Azure enforces limits on tags (number of tags per resource and maximum lengths for key/value). These limits can change — check the Azure documentation for the current service limits before designing your tagging strategy.
- Azure tags documentation: https://learn.microsoft.com/azure/azure-resource-manager/management/tag-resources
- Azure Policy for tags: https://learn.microsoft.com/azure/governance/policy/
- Azure resource limits and quotas: https://learn.microsoft.com/azure/azure-resource-manager/management/azure-subscription-service-limits
- Tags are key-value metadata used for identification, logical grouping, automation, and cost management.
- Tags can be applied at subscription, resource group, or resource level — but they do not inherit automatically.
- For billing and reporting, ensure tags are present on resources or use Azure Policy to apply/copy tags to resources.
- Use the portal, Azure CLI, PowerShell, or policies to add, edit, filter, and manage tags consistently across your Azure estate.