Alerts & Action Groups
Alert rules · alert states · action groups · alert processing rules · roles
By the tools4free.dev team · Last reviewed November 13, 2026
Practice questions for this topic →
Alert rules and types
An alert rule is the resources to monitor, a signal and a condition. When the condition is met, an alert fires and triggers its action groups. With several monitored resources, the condition is evaluated and alerts fire per resource.
| Type | Use it for | Notes |
|---|---|---|
| Metric | Numeric metrics. Fast, because it uses precomputed metric data | Multiple conditions (up to 5, single resource), dimensions and dynamic thresholds. Microsoft's pages differ on the default state: the types page says stateful by default, the create page says unticking Automatically resolve alerts makes it stateless. One rule can monitor many resources of the same type in the same region, but not VM guest metrics or VM network metrics |
| Log search | Specific data in logs, or advanced logic. Runs a KQL query at a set frequency; can measure table rows or a numeric column | Poor for "no data" detection: use a metric alert for heartbeat-style absence |
| Activity log | A matching activity log event, such as a VM deleted or a role assigned | Includes Service Health and Resource Health alerts. All activity log alerts are stateless and never auto-resolve |
| Smart detection, Prometheus | Other alert types in the overview | Not covered further here |
Service Health alerts are about platform-wide service issues. Resource Health alerts are about the health of one resource. Both are activity log alerts.
Alert states
- Two separate states: alert condition (Fired or Resolved, set by the system) and user response (New, Acknowledged or Closed, set by you).
- Stateless alerts fire every time the condition is met. Stateful alerts fire once and do not fire again until resolved.
- A stateful metric alert resolves after three consecutive checks without the condition. The Automatically resolve alerts option makes a metric alert stateful; unticked makes it stateless. (Microsoft's alert types page also says metric alerts are stateful by default.)
- Alerts are stored for 30 days, then deleted. Fired alert instances are read-only.
- Splitting a metric alert by dimensions creates separate alerts per dimension combination, each charged separately.
Create a metric alert rule
- Portal: Monitor › Alerts › + Create › Alert rule › Scope › Condition (signal, static or dynamic threshold, operator, aggregation Sum, Count, Average, Min or Max) › Check every and lookback period › Actions (action group) › Details (subscription, resource group, severity, name) › Review + create.
- Dynamic thresholds use machine learning on history. Sensitivity is High, Medium (default) or Low. They can't be used when the rule has multiple conditions.
- A metric alert rule can't be renamed. Its name must be unique per resource group, must not end with a space or period, and resource group name plus rule name can be at most 252 characters.
- Permissions: Read on the target resource, Write on the resource group where the rule is created, and Read on any action group used. Built-in roles: Monitoring Contributor to create, Monitoring Reader to view.
Action groups
- An action group is a reusable set of notifications and actions. One alert rule can use up to 5 action groups. Many rules can share one group. Actions run concurrently, in no set order.
- Create (portal): Monitor › Alerts › Action groups › Create › subscription, resource group, region (Global or a specific region), action group name and display name › Notifications tab › Actions tab › Tags › Review + create.
- Test: save the action group first, then use Test and choose a sample type. Test notifications carry "Test" in the subject.
- Email receivers must be verified with a one-time passcode within 30 minutes of saving. Email to an Azure Resource Manager role needs no passcode.
- Email to an ARM role works only for Owner, Contributor, Reader, Monitoring Contributor and Monitoring Reader, assigned to a user or group at subscription level. It can take up to 24 hours to start.
- SMS replies: STOP and START affect all groups. DISABLE and ENABLE name one group.
- Secure webhook needs Microsoft Entra authentication. A plain Webhook can use basic authentication only with the credentials in the URI.
- Common alert schema: one unified payload across alert types. Opt in per receiver in the action group.
- Runbook actions now use a managed identity. Azure Automation Run As accounts were retired on Sep 30, 2023.
| Notification types | Action types |
|---|---|
| Email, email Azure Resource Manager role, SMS, Azure app push, voice | Automation runbook, Event Hubs, Functions, ITSM, Logic Apps, Secure webhook, Webhook |
Alert processing rules
Alert processing rules were called "action rules" (resource type Microsoft.AlertsManagement/actionRules). They change how alerts are handled after they fire. A normal alert rule generates alerts; a processing rule does not.
| Rule type | Effect | Notes |
|---|---|---|
| Suppress notifications | Removes action groups from fired alerts | The alerts still fire and stay visible in the portal, Resource Graph and the API. Suppression has priority over "apply action groups" |
| Apply action group | Adds action groups to fired alerts | Use it for alerts whose source can't specify action groups, such as Azure Backup alerts and VM insights guest health alerts |
- Disabling vs suppressing: disabling an alert rule stops alerts firing at all (and may also stop alerts for resources not in maintenance). Suppression lets alerts fire but removes the notifications.
- Processing rules do not affect Azure Service Health alerts. The scope must be in the same subscription as the rule.
- Wizard tabs: Scope, Rule settings (Suppress notifications or Apply action group), Scheduling (always, one-time or recurring), Details, Tags.
- New or updated rules can take up to 30 minutes to take effect.
- Filters: AND between filters, OR between up to 5 values in one filter. Fields include severity, resource type, resource group, alert rule name or ID, monitor condition and monitor service.
- Azure Backup built-in alerts feed Azure Monitor alerts, so action groups and alert processing rules apply to them.
Limits
| Item | Value |
|---|---|
| Alert retention | 30 days |
| Action groups per alert rule | 5 |
| Email passcode validity | 30 minutes |
| Conditions per metric alert rule | Up to 5 (single resource) |
| Stateful metric alert resolves after | 3 consecutive checks without the condition |
| Alert processing rule delay | Up to 30 minutes to take effect |
| Values per processing-rule filter | 5 |
| Webhook retries | Up to 5 retries (delays of 5, 20 and 40 seconds), then none for 15 minutes |
CLI and PowerShell
| Task | Azure CLI | PowerShell |
|---|---|---|
| Create an alert processing rule | az extension add --name alertsmanagement, then az monitor alert-processing-rule create --name N --rule-type AddActionGroups --scopes /subscriptions/SUB1 --action-groups <id> --resource-group RG | Set-AzAlertProcessingRule -Name N -AlertProcessingRuleType AddActionGroups -Scope /subscriptions/SUB1 -ActionGroupId <id> -ResourceGroupName RG |
| List, show, update, delete processing rules | az monitor alert-processing-rule list|show|update|delete | Get-, Update-, Remove-AzAlertProcessingRule |
| Create a metric alert | az monitor metrics alert create --name N --resource-group RG --scopes <id> --condition "avg Percentage CPU > 90". Required: --condition, --name, --resource-group, --scopes. Optional include --action, --auto-mitigate, --description. The condition string is an illustration | Not covered on the page |
| Create an action group | az monitor action-group create --name N --resource-group RG plus receiver options such as --action, --arm-role-receivers, --automation-runbook-receivers, --azure-app-push-receivers, --azure-function-receivers | Not covered on the page |
| Create an action group as code | ARM resource Microsoft.Insights/actionGroups | Same template |
Exam Tips
Tick each tip once you can answer it without looking.
“Silence notifications for all VMs in a resource group every Sunday night” → Alert processing rule (suppression, recurring schedule) scoped to the resource group. Trap: Disabling an alert rule stops alerts firing at all, not just the notifications.
“Azure Backup alerts must email the ops team, and the alerts have no action group option” → Alert processing rule that applies an action group. Trap: Backup alerts come from a source that can't specify action groups, so there is no alert rule to edit for this.
“Is a suppressed alert still visible?” → Yes: it still fires and is listed; only the action groups are removed. Trap: Suppression doesn't stop the alert being created.
“A suppression rule and an apply-action-group rule both match an alert” → Suppression wins. Trap: Suppression has priority over applying action groups.
“Alert processing rule should also silence Service Health alerts” → Not possible: processing rules don't affect Service Health alerts.
“Processing rule scope includes resources in a second subscription” → Not allowed: the scope must be in the same subscription as the rule.
“Alert when any of 50 VMs in one region has CPU above 90%, with one rule” → Metric alert rule scoped to the VMs. Trap: A multi-resource rule needs the same resource type and the same region.
“Alert on guest memory across many VMs with one metric alert rule” → Not supported: multi-resource metric alert rules don't support VM guest metrics.
“Alert when a VM is deleted” → Activity log alert. Trap: A metric alert watches a numeric metric, not an activity log event.
“Activity log alert stays Fired forever” → Expected: activity log alerts are stateless and never auto-resolve; set the user response to Closed.
“Alert logic based on a KQL query over logs” → Log search alert. Trap: A metric alert uses precomputed metric data, not a query.
“Detect that a machine stopped sending heartbeats” → Metric alert. Trap: Log search alerts are poor at detecting "no data".
“Same notifications for 20 alert rules” → Reuse one action group. Trap: A rule can use at most 5 action groups, and many rules can share one.
“Call a webhook protected by Microsoft Entra ID” → Secure webhook. Trap: A plain Webhook uses basic authentication with the credentials in the URI.
“Email receiver added, but no email arrives” → The address wasn't verified: enter the one-time passcode within 30 minutes of saving (resend if needed).
“User must create alert rules but not manage other resources” → Monitoring Contributor. Trap: Monitoring Reader can only view.
“Rename a metric alert rule” → Not possible: a metric alert rule can't be renamed, so delete it and recreate it.
“Dynamic thresholds on a rule with two conditions” → Not supported: dynamic thresholds can't be used when the rule has multiple conditions.
“A metric alert resolves on its own” → Stateful: it resolves after 3 consecutive checks without the condition. Trap: Unticking Automatically resolve alerts makes it stateless.
Sources
- Overview of Azure Monitor alerts
- Types of Azure Monitor alerts
- Create and manage action groups
- Alert processing rules
- Create metric alert rules
- az monitor metrics alert
- az monitor action-group
- Azure Backup monitoring alerts
Checked against Microsoft Learn on November 13, 2026.