CodeMIRAI
0 XP

Tags

2 min read Quiz included

As you create more resources, it gets hard to tell which ones belong to which project, team or environment. Tags solve that.

What a tag is

A tag is a name/value pair of metadata you attach to a resource, resource group or subscription:

NameValue
DepartmentFinance
EnvironmentProduction
CostCenterCC-4021
Ownerasha@example.com

A resource can have up to 50 tags. Tag names are not case-sensitive, but values are.

What tags are used for

  • Cost management: group and report costs by tag (for example, by department) in Cost Management.
  • Resource management: find all resources for a project, an environment or an owner.
  • Operations: mark resources by how critical they are, or by their SLA.
  • Security: classify data sensitivity.
  • Governance and compliance: identify resources that must meet a standard, such as ISO 27001.
  • Automation: scripts can act on tags, for example shutting down every VM tagged Environment: Dev each night.

Important behaviour

  • Tags are not inherited automatically. A tag on a resource group does not appear on the resources inside it.
  • To require tags, or to copy a tag from a resource group onto its resources, use Azure Policy.
Finished this lesson?Mark it complete to earn +20 XP and move your progress on.