Send metric alert notifications to a custom outbound webhook, for example a chat channel or an external system, instead of, or alongside, Coralogix-native routing. Use this when a metric alert needs to reach a destination you drive through a generic webhook payload.

Custom webhooks attach to a [metric alert](https://coralogix.com/docs/user-guides/alerting/create-an-alert/metrics/threshold-alerts/index.md) on the Notification step of the [alert creation wizard](https://coralogix.com/docs/user-guides/alerting/configuring-alert-definition/index.md). The webhook-specific setup is below; for the rest of the wizard, see [Configuring an alert definition](https://coralogix.com/docs/user-guides/alerting/configuring-alert-definition/index.md).

## What you need

- A [generic outbound webhook](https://coralogix.com/docs/user-guides/alerting/outbound-webhooks/generic-outbound-webhooks-alert-webhooks/index.md), or another custom webhook, already created
- A metric alert you are creating or editing

## Attach a custom webhook

To add a custom webhook to a metric alert, go to **Alerts**, then select **Create alert** (or open an existing metric alert). On the Notification step of the wizard:

1. Select the **Alerts, Signal-Based** notification path.
1. Add your webhook under **Custom notifications**. Legacy outbound webhooks live here.

You can attach more than one webhook to drive several destinations from a single alert.

### Group-by behavior

How notifications map to webhook payloads depends on whether the alert uses **Group by** on the Condition step:

- **Trigger a single notification** when at least one combination of the group-by values meets the condition. One notification aggregates all matching values.
- **Trigger a separate notification for each combination** that meets the condition. Select one or more keys, a subset of the fields used in the alert condition, and a separate notification is sent for each key.
- To populate the `$GROUP_BY_VALUE_1` [placeholder](https://coralogix.com/docs/user-guides/alerting/outbound-webhooks/generic-outbound-webhooks-alert-webhooks/#placeholders) in the webhook payload, the metric must be grouped by that field.
- The number of **Group by** permutations is limited to 1000. When more exist, only the first 1000 are tracked.

When no **Group by** is set, a single notification is sent when the query meets the condition.

### Notification cadence

- **Notify every**: sets the cadence. After a notification is sent, the alert keeps evaluating, but notifications are suppressed for the duration of the period.
- **Notify when resolved**: sends a follow-up notification once the condition clears.

## Related resources

[Threshold alerts](https://coralogix.com/docs/user-guides/alerting/create-an-alert/metrics/threshold-alerts/) [Configuring an alert definition](https://coralogix.com/docs/user-guides/alerting/configuring-alert-definition/) [Generic outbound webhooks](https://coralogix.com/docs/user-guides/alerting/outbound-webhooks/generic-outbound-webhooks-alert-webhooks/)

## Next steps

Configure metric threshold-based alerting in [Threshold alerts](https://coralogix.com/docs/user-guides/alerting/create-an-alert/metrics/threshold-alerts/index.md).
