# How to block websites and domains using Microsoft Defender for Endpoint custom indicators

Author: [Opeyemi Enitan](https://blog.threatintels.org/blog/about.html)

Canonical article: https://blog.threatintels.org/blog/defender-endpoint-custom-domain-url-indicators.html

Historical project period: 2025 (2025)

## Why this matters

When threat intelligence or an investigation identifies a malicious website, a security team may need to prevent managed endpoints from reaching it before more users encounter phishing, malware or fraudulent content. A block that exists only in the portal is not sufficient if endpoints or browsers do not enforce it.

This guide explains how to configure scoped Defender for Endpoint indicators, confirm the relevant protection settings, test enforcement safely and troubleshoot inconsistent results.

# How to block websites and domains using Microsoft Defender for Endpoint custom indicators

A website block can look correct in the Microsoft Defender portal and still fail on a laptop. The reason is often not the domain indicator itself: browser enforcement, Network Protection, device scope and HTTPS protocol behaviour all matter. This guide shows a safe way to configure a **specific domain or URL indicator** without confusing it with category-based Web Content Filtering.

This is a general implementation walkthrough based on previously discussed Defender website-blocking work. Example domains and outcomes are synthetic; the commands below have not been executed in the author's current environment.

## What this control does

Microsoft Defender for Endpoint custom network indicators can **allow, warn or block** specified external IPs, URLs or domains. Microsoft Edge relies on SmartScreen for browser integration; other browsers and processes rely on Network Protection in block mode. This is distinct from **Web Content Filtering**, which controls website categories, and from DNS filtering, which may operate independently.

### Prerequisites and permissions

- An eligible Defender for Endpoint subscription and an onboarded, supported test device.
- Defender portal access with permission to manage indicators, and a role able to view endpoint configuration and hunting data.
- **Settings → Endpoints → General → Advanced features → Custom network indicators** enabled.
- SmartScreen enabled for Microsoft Edge; for non-Microsoft browsers, Defender Antivirus active, behaviour monitoring and cloud protection enabled, and Network Protection in **block** mode.
- A dedicated device group for pilot scope, and an approved **test domain you control**. Do not block Microsoft, authentication, payroll or production SaaS domains for demonstration.

The latest Microsoft prerequisites include supported platform and browser-specific exceptions; confirm the device OS before rollout.

## Step 1 — Read current device protection state

On a **Windows** test endpoint, run these read-only commands in an authorised PowerShell session:

powershell

```
Get-MpComputerStatus |
  Select-Object AMRunningMode,AntivirusEnabled,RealTimeProtectionEnabled,
                BehaviorMonitorEnabled,IoavProtectionEnabled

Get-MpPreference |
  Select-Object EnableNetworkProtection,MAPSReporting,DisableBlockAtFirstSeen
```

Interpret `EnableNetworkProtection` carefully: `0` = disabled, `1` = block, `2` = audit. These checks are not sufficient to prove that Defender for Endpoint is onboarded or that cloud services are reachable. Also verify endpoint health and applied policies in the portal.

For a pilot managed by Intune, inspect the effective **Endpoint security → Attack surface reduction → Network protection** policy and assignment. Use the portal's current navigation if Microsoft renames a menu. Do not set conflicting GPO, Intune and local policies to different states.

## Step 2 — Inspect tenant indicator configuration

In [Microsoft Defender](https://security.microsoft.com/), open **Settings → Endpoints → General → Advanced features** and verify **Custom network indicators**. Next navigate to **Settings → Endpoints → Indicators → URLs/Domains**. Review existing entries, expiry, actions, device groups and conflicting allow entries before creating a new one.

## Step 3 — Create a scoped block

- Select **Add item** in the **URLs/Domains** tab.
- Enter a controlled test FQDN such as `block-test.example.org` **only if you own and host it**; do not expect the reserved example domain to produce a real network test.
- Choose **Block**, set a short expiry and document why the entry exists.
- Limit **Scope** to a dedicated pilot device group rather than all devices.
- Review the summary and save. Record the indicator identifier privately for rollback.

**Important:** Microsoft's indicator precedence is **Allow > Warn > Block** for matching indicators. An allow entry may explain why a block appears ineffective. Microsoft notes indicator rollout can take **up to 48 hours**, though usually less than two hours; do not assume immediate propagation.

## Step 4 — Validate with positive and negative tests

Use a test site you control and a pilot device. Confirm a baseline connection **before** enabling the block, then reattempt after policy propagation. Repeat in Edge and a non-Microsoft browser only if its Network Protection requirements are met.

<table><tr><th>Test</th><th>Evidence to collect</th><th>What it means</th></tr><tr><td>Controlled test FQDN before indicator</td><td>Site loads and timestamp</td><td>Baseline only</td></tr><tr><td>Same FQDN after propagation</td><td>Browser block page / endpoint notification</td><td>Enforcement for that browser/device</td></tr><tr><td>Unrelated approved FQDN</td><td>Still loads</td><td>Basic negative control</td></tr><tr><td>Non-Microsoft browser</td><td>Block with Network Protection in block mode</td><td>Browser coverage, not universal HTTPS-path filtering</td></tr><tr><td>Device outside pilot group</td><td>Not subject to pilot indicator</td><td>Scope check; other protections may still block it</td></tr><tr><td>Indicator expired or removed</td><td>Connection retested after propagation</td><td>Rollback validation</td></tr></table>

## Step 5 — Investigate why the block did not work

Check in order: device onboarding/health; indicator enablement; pilot group assignment; expiry; **allow** conflicts; SmartScreen (Edge); Network Protection block mode (other browsers); browser caching; propagation delay; and TLS/QUIC limitations.

For HTTPS in non-Microsoft browsers, a **full URL path** is not reliably enforceable by Network Protection: use an FQDN indicator where appropriate. QUIC and Encrypted ClientHello can prevent FQDN inspection; browser policy changes require their own approval and compatibility testing. HTTP/2 connection coalescing also has documented limitations.

A `ConnectionSuccess` event in network connection telemetry does **not** necessarily disprove Network Protection blocking: the TCP connection can succeed before the application-layer block decision. Inspect the protection-specific evidence and actual user experience.

### Reusable advanced hunting query

Run in Defender XDR Advanced Hunting; adjust the lookback and test-device name. This is an **exploratory pivot**, not proof of blocking from a single event.

kusto

```
let device = "TEST-WIN11-01";
let lookback = 2d;
DeviceEvents
| where Timestamp > ago(lookback)
| where DeviceName =~ device
| where ActionType has_any ("NetworkProtection", "SmartScreen", "ExploitGuard")
| project Timestamp, DeviceName, ActionType, FileName,
          RemoteUrl, AdditionalFields
| order by Timestamp desc
```

Schema availability and event names vary by platform and sensor. Check **ActionType** reference and available events before interpreting zero results; correlate with the endpoint timeline and user-facing block.

## Monitoring, limitations and rollback

Monitor block-related endpoint events, indicator expiry and service desk reports after rollout. Do not use a broad domain block to fix a narrowly scoped URL issue without assessing subdomains and business dependencies.

To roll back, locate the test indicator in **Settings → Endpoints → Indicators → URLs/Domains**, remove or change the specific indicator, and wait for policy propagation. If Network Protection was changed for the pilot, restore the previously recorded policy **only through its authoritative management channel**. Confirm the test domain's reachability and absence of unintended side effects. Do not disable tenant-wide web protection to undo one indicator.

## References

- [Microsoft Learn: Create indicators for IPs and URLs/domains](https://learn.microsoft.com/en-us/defender-endpoint/indicator-ip-domain)
- [Microsoft Learn: Network protection](https://learn.microsoft.com/en-us/defender-endpoint/network-protection)
- [Microsoft Defender portal](https://security.microsoft.com/)

[← Browse more guides](https://blog.threatintels.org/blog/index.html)
