Onboarding Devices to Defender for Endpoint
Earn 25 points (50 with Pro) in two steps
- ① Read through the lesson — each section gets a ✓ as you scroll through it.
- ② When every section has a ✓, tap Complete lesson.
0 of 11 read · keep scrolling
✦ See fewer ads and earn double points — 50 a lesson instead of 25 — with Pro
Lesson: Onboarding Devices to Microsoft Defender for Endpoint
Introduction: Why Device Onboarding is the Foundation of Security
In the modern digital landscape, the perimeter is no longer a physical office wall or a single firewall. With the rise of remote work, mobile devices, and cloud-based resources, the endpoint—your laptops, desktops, servers, and mobile hardware—has become the new front line of defense. If a device is not being monitored, it is effectively a blind spot in your security posture. Onboarding devices to Microsoft Defender for Endpoint (MDE) is the critical process of enrolling these assets into the unified security management ecosystem.
When you onboard a device, you are essentially installing a sensor that reports telemetry back to the Defender XDR portal. This telemetry includes behavioral data, process executions, network connections, and system changes. Without this onboarding process, your security team is flying blind, unable to detect lateral movement, credential theft, or malware execution until it is too late. By mastering the onboarding process, you transform your fleet from a collection of isolated machines into a coordinated, observable defense network.
This lesson explores the technical mechanics of onboarding, the various deployment methods available, and the best practices for ensuring that your security coverage is complete, accurate, and manageable. We will move beyond the basic "click here" instructions and dive into the architecture of how these agents communicate, how to troubleshoot common failures, and how to maintain security hygiene over the lifecycle of a device.
Not read yet
Understanding the Onboarding Architecture
Before we jump into deployment scripts and Group Policy Objects, it is important to understand what is actually happening under the hood. Microsoft Defender for Endpoint relies on a combination of built-in Windows components and a specialized agent that communicates with the Microsoft cloud.
For Windows 10 and 11, the sensor is built into the operating system. You do not need to install a heavy, third-party antivirus agent that consumes massive amounts of RAM. Instead, you are enabling the "Sense" service—the Microsoft Defender for Endpoint service—which activates the monitoring capabilities already present in the kernel. For other platforms like Linux, macOS, or legacy Windows Server versions, you will install a dedicated agent package that provides similar functionality.
The onboarding process involves three primary steps:
- The Configuration Package: A small file (often a script or a configuration profile) that identifies your specific tenant and tells the device where to send its data.
- The Sensor Activation: The device runs the package, which generates a unique identity for the machine and establishes a secure connection to the Microsoft cloud backend.
- Telemetry Reporting: Once the connection is established, the device begins streaming behavioral data to the Defender XDR portal, where it is analyzed by machine learning models and security analysts.
Callout: Agentless vs. Agent-Based Onboarding It is a common misconception that MDE requires a heavy agent on all devices. On modern Windows platforms, the "agent" is effectively an existing feature that is simply toggled on. This is a significant advantage over legacy security solutions, as it reduces the performance impact on the machine and minimizes the risk of software conflicts during updates.
Not read yet
Deployment Methods: Choosing the Right Path
The method you choose for onboarding depends heavily on how you manage your devices today. A small business with a handful of machines might use a local script, while a global enterprise with thousands of endpoints will rely on automation tools like Microsoft Intune or Group Policy.
1. Microsoft Intune (Mobile Device Management)
Intune is the preferred method for modern organizations. It allows you to create a configuration profile that automatically targets devices based on dynamic groups. If a new laptop is enrolled in Intune, it is automatically onboarded to Defender for Endpoint without any manual intervention.
2. Group Policy (Active Directory)
For organizations that rely on traditional on-premises domain controllers, Group Policy is the standard. You can distribute a registry-based configuration script to all machines in an Organizational Unit (OU). This ensures that every machine joined to the domain is automatically secured.
3. Local Scripts
This is primarily used for testing or for a small set of servers that are not managed by a central tool. You download a script from the Defender portal and run it with administrative privileges on the target machine. While simple, this method does not scale well and is prone to human error.
4. Configuration Manager (MECM)
For enterprises that use the Microsoft Endpoint Configuration Manager, you can deploy the onboarding package as an application or a configuration baseline. This is ideal for large-scale server environments where you need precise control over the deployment timing.
Tip: Prioritize Modern Management If your organization is in the process of moving to the cloud, prioritize Intune for onboarding. It provides a more robust feedback loop, showing you exactly which devices are onboarded, which are pending, and which have errors, all within a single dashboard.
Not read yet
Step-by-Step: Onboarding Windows Devices via Intune
Intune provides a seamless experience for onboarding. Follow these steps to configure your environment:
- Access the Defender Portal: Navigate to the Microsoft Defender portal (security.microsoft.com).
- Settings: Go to Settings > Endpoints > Onboarding.
- Select Platform: Choose "Windows 10 and 11" as the operating system.
- Select Deployment Method: Choose "Microsoft Intune" from the drop-down menu.
- Download the Package: Click the button to download the configuration package (a
.intunemgmtfile). - Create Profile in Intune:
- Log in to the Intune admin center.
- Navigate to Endpoint security > Endpoint detection and response.
- Create a new policy.
- Select the platform and the "Endpoint detection and response" profile type.
- Upload the configuration file you downloaded earlier.
- Assign the Profile: Assign the policy to a group containing the devices you want to onboard.
After assigning the policy, the devices will receive the configuration during their next sync cycle. You can monitor the status in the Defender portal under the Device inventory section.
Not read yet
Onboarding Non-Windows Devices (Linux and macOS)
While Windows is the primary focus, modern environments are heterogeneous. Securing Linux servers and macOS workstations is just as important.
Linux Onboarding
Onboarding Linux requires installing the mdatp package. You will need to download the onboarding package from the Defender portal, which includes a configuration file (mdatp_onboard.json).
- Install the Repository: You must add the Microsoft package repository to your Linux distribution (e.g., Ubuntu, RHEL, CentOS).
- Install the Agent: Use your package manager (e.g.,
aptoryum) to installmdatp. - Apply the Configuration: Copy the
mdatp_onboard.jsonfile to the/etc/opt/microsoft/mdatp/directory. - Verify: Run
mdatp healthto ensure the agent is running and communicating with the cloud.
macOS Onboarding
MacOS onboarding is typically handled via a Mobile Device Management (MDM) solution like Intune or Jamf. You will deploy a configuration profile (a .mobileconfig file) that grants the necessary permissions to the Defender extension.
Warning: Full Disk Access on macOS MacOS has strict security controls. If you do not grant "Full Disk Access" to the Microsoft Defender extension via your MDM profile, the agent will not be able to scan files effectively. Always verify that your MDM configuration includes these system extension approvals.
Not read yet
Troubleshooting Common Onboarding Pitfalls
Even with careful planning, things can go wrong. Understanding how to diagnose these issues is a key skill for any security administrator.
The "Device Not Showing Up" Problem
If you have run the onboarding script but the device does not appear in the Defender portal, check the following:
- Connectivity: Ensure the device can reach the required Microsoft URLs. The agent needs to talk to the internet to report telemetry.
- Time Sync: If the system clock is significantly off, TLS handshakes will fail, and the device will be unable to authenticate with the cloud.
- Proxy Settings: If your organization uses a proxy, you must ensure the Defender agent is configured to use it. You can set this via registry keys or the
mdatpconfiguration file on Linux.
The Client Analyzer Tool
Microsoft provides a powerful tool called the Microsoft Defender for Endpoint Client Analyzer. This is a script you run on a problematic device. It performs a battery of tests, checking for connectivity, service status, and configuration errors.
# Example of running the Client Analyzer on Windows
.\MDEClientAnalyzer.exe -o C:\Temp\Results
The output is a detailed HTML report that tells you exactly why the onboarding is failing. It is the first tool you should reach for when a device is "stuck" in a non-reporting state.
Not read yet
Best Practices for Enterprise Deployment
To maintain a healthy security environment, follow these industry-standard practices:
- Phased Rollout: Never roll out security changes to your entire fleet at once. Start with a "pilot" group of IT workstations, then move to a department-specific group, and finally roll out to the rest of the organization.
- Automate Verification: Use KQL (Kusto Query Language) in the Defender portal to verify that your onboarding coverage matches your expected inventory.
// KQL query to find devices that are not onboarded DeviceInfo | summarize arg_max(Timestamp, *) by DeviceId | where OnboardingStatus != "Onboarded" - Keep Agents Updated: Ensure that your OS and agent versions are up to date. Security threats evolve, and the agent needs the latest definitions and behavioral logic to detect new attack patterns.
- Monitor Health States: Use the "Device health" dashboard in the Defender portal. It will highlight devices that have outdated antivirus signatures or are experiencing service crashes.
- Least Privilege: When running onboarding scripts, ensure they are executed with the appropriate administrative context, but avoid leaving administrative credentials stored in plain text within your deployment scripts.
| Feature | Windows | Linux | macOS |
|---|---|---|---|
| Deployment | GPO, Intune, Script | Package Manager | MDM Profile |
| Primary Tool | Built-in | mdatp | System Extension |
| Monitoring | Defender XDR | Defender XDR | Defender XDR |
| Configuration | Registry | JSON File | .mobileconfig |
Not read yet
Advanced Concepts: Connectivity and Proxy Configuration
One of the most common reasons onboarding fails in large corporate environments is the presence of strict network filtering. The Defender agent requires access to specific URLs to report data. If your firewall or web proxy blocks these, the agent will effectively be "off" even if the installation is successful.
URL Requirements
You must ensure that your network allows traffic to the following endpoints:
*.security.microsoft.com*.blob.core.windows.net(for downloading updates)*.events.data.microsoft.com(for telemetry reporting)
If you are using a proxy, you have a few options to configure the agent. On Windows, you can use the netsh command to set the WinHTTP proxy settings, which the Defender service respects.
netsh winhttp set proxy proxy-server="http://proxy.yourcompany.com:8080"
Understanding Telemetry Levels
Defender for Endpoint allows you to configure the amount of data sent to the cloud. While you can set this to "Basic," it is highly recommended to leave it at "Full." The "Full" telemetry level allows the Defender XDR backend to perform deep behavioral analysis, which is essential for detecting advanced persistent threats (APTs) that do not rely on traditional file-based malware.
Callout: Telemetry Privacy Many organizations worry about the privacy implications of "Full" telemetry. It is important to note that Microsoft does not use this data for advertising. The telemetry is strictly used for security analysis and to provide you with the detection capabilities of the XDR platform. The data is encrypted in transit and at rest.
Not read yet
Managing the Lifecycle: Offboarding and Re-onboarding
Sometimes, a device must be removed from the environment. Perhaps it is being decommissioned, sold, or repurposed. Simply deleting the device from the Defender portal is not enough; you should also run an offboarding script to clean up the local sensor configuration.
The Offboarding Process
If you don't offboard a device, the sensor may continue to try to send data to the cloud, resulting in errors in your logs. You can download the offboarding package from the same location where you found the onboarding package in the Defender portal.
- Download: Get the offboarding script for the specific OS.
- Execute: Run the script with administrative privileges on the target device.
- Verification: The device will stop reporting telemetry within a few minutes. You can then safely remove it from your management tool (Intune or AD).
When to Re-onboard
You may need to re-onboard a device if it has been reimaged or if the sensor has become corrupted. If a device appears in the portal but has not checked in for several days, perform the following:
- Check the local service status (
Senseservice on Windows). - Run the Client Analyzer.
- If the service is broken, run the onboarding script again to overwrite the existing configuration.
Not read yet
Common Questions and FAQs
Can I onboard devices to both Microsoft Defender and a third-party antivirus?
Yes, you can use Defender for Endpoint in "EDR in Block Mode." This allows a third-party antivirus to handle the primary scanning, while Defender provides the behavioral analysis and blocking capabilities for threats that the antivirus might miss.
How do I onboard devices that are off-network?
Because the onboarding process communicates over HTTPS, devices do not need to be on the corporate VPN to onboard or report telemetry. As long as they have internet access, they will communicate with the Microsoft cloud.
Does onboarding impact device performance?
The sensor is designed to be lightweight. It uses kernel-level monitoring to ensure it only inspects relevant events, minimizing CPU and memory impact. You should see negligible performance impact on modern hardware.
What if my device is offline for a long period?
The agent will buffer data locally. Once the device reconnects to the internet, it will upload the cached telemetry. However, if the device is offline for a very long time, it may eventually stop reporting, and you will need to investigate the device state.
Not read yet
Summary and Key Takeaways
Onboarding devices to Microsoft Defender for Endpoint is a foundational task that turns your hardware into an active participant in your security strategy. By following a structured approach, you ensure that your security teams have the visibility they need to stop threats before they escalate.
Key Takeaways:
- Visibility is Everything: You cannot protect what you cannot see. Onboarding is the process of establishing that visibility.
- Use Modern Tools: Prioritize Intune for Windows onboarding to take advantage of automated enrollment and centralized management.
- Understand the Architecture: Know that on Windows, you are enabling a built-in sensor, whereas on other platforms, you are deploying a specific agent.
- Test Before You Deploy: Always use a phased approach to identify potential network or configuration issues before a global rollout.
- Leverage the Client Analyzer: When in doubt, use the Microsoft-provided diagnostic tools to troubleshoot connectivity and configuration errors.
- Maintain Hygiene: Regularly audit your onboarded devices using KQL queries to ensure your coverage remains consistent as your fleet changes.
- Respect Security Boundaries: Always ensure that necessary URLs are allowed through your firewalls and proxies to avoid "silent" onboarding failures.
By mastering these steps and maintaining a rigorous approach to device management, you create a robust security posture that is capable of scaling with your organization's needs. Remember that security is not a "set and forget" task; it is an ongoing process of monitoring, verifying, and refining your configurations to stay ahead of evolving threats.
Not read yet
Each section gets a ✓ as you scroll through it. Tap the button to jump to the next one.
- Creating a Microsoft 365 Tenant
- Creating a Microsoft 365 Tenant Quiz5q
- Implementing and Managing Domains
- Implementing and Managing Domains Quiz5q
- Configuring Organization Settings
- Configuring Organization Settings Quiz5q
- Monitoring Microsoft 365 Service Health
- Monitoring Microsoft 365 Service Health Quiz5q
- Configuring Network Connectivity Insights
- Configuring Network Connectivity Insights Quiz5q
- Managing Software Updates in Microsoft 365
- Managing Software Updates in Microsoft 365 Quiz5q
- Monitoring Microsoft 365 Adoption and Usage
- Monitoring Microsoft 365 Adoption and Usage Quiz5q
- Configuring Microsoft 365 Backup
- Configuring Microsoft 365 Backup Quiz5q
- Creating and Managing Users in Microsoft Entra ID
- Creating and Managing Users in Microsoft Entra ID Quiz5q
- Managing External Users and Guest Access
- Managing External Users and Guest Access Quiz5q
- Creating and Managing Contacts
- Creating and Managing Contacts Quiz5q
- Creating and Managing Microsoft 365 Groups
- Creating and Managing Microsoft 365 Groups Quiz5q
- Managing Shared Mailboxes
- Managing Shared Mailboxes Quiz5q
- Managing Microsoft 365 Licenses
- Managing Microsoft 365 Licenses Quiz5q
- Performing Bulk User Management with PowerShell
- Performing Bulk User Management with PowerShell Quiz5q
- Implementing Group-Based Licensing
- Implementing Group-Based Licensing Quiz5q
- Implementing Roles in Microsoft 365
- Implementing Roles in Microsoft 365 Quiz5q
- Managing Microsoft Entra ID Roles
- Managing Microsoft Entra ID Roles Quiz5q
- Managing Permissions for Microsoft Defender XDR
- Managing Permissions for Microsoft Defender XDR Quiz5q
- Managing Delegation with Administrative Units
- Managing Delegation with Administrative Units Quiz5q
- Managing Roles with Privileged Identity Management
- Managing Roles with Privileged Identity Management Quiz5q
- Managing Microsoft Purview Permissions
- Managing Microsoft Purview Permissions Quiz5q
- Preparing for Identity Synchronization
- Preparing for Identity Synchronization Quiz5q
- Using IdFix for Directory Cleanup
- Using IdFix for Directory Cleanup Quiz5q
- Implementing Microsoft Entra Connect Sync
- Implementing Microsoft Entra Connect Sync Quiz5q
- Implementing Microsoft Entra Cloud Sync
- Implementing Microsoft Entra Cloud Sync Quiz5q
- Monitoring with Microsoft Entra Connect Health
- Monitoring with Microsoft Entra Connect Health Quiz5q
- Troubleshooting Synchronization Issues
- Troubleshooting Synchronization Issues Quiz5q
- Implementing Authentication Methods
- Implementing Authentication Methods Quiz5q
- Implementing Self-Service Password Reset
- Implementing Self-Service Password Reset Quiz5q
- Implementing Microsoft Entra Password Protection
- Implementing Microsoft Entra Password Protection Quiz5q
- Investigating Authentication Issues
- Investigating Authentication Issues Quiz5q
- Configuring Passwordless Authentication
- Configuring Passwordless Authentication Quiz5q
- Planning for Identity Protection
- Planning for Identity Protection Quiz5q
- Implementing Microsoft Entra Identity Protection
- Implementing Microsoft Entra Identity Protection Quiz5q
- Planning Conditional Access Policies
- Planning Conditional Access Policies Quiz5q
- Implementing Conditional Access Policies
- Implementing Conditional Access Policies Quiz5q
- Implementing Multifactor Authentication
- Implementing Multifactor Authentication Quiz5q
- Configuring Named Locations
- Configuring Named Locations Quiz5q
- Understanding Microsoft Security Exposure Management
- Understanding Microsoft Security Exposure Management Quiz5q
- Managing Microsoft Secure Score
- Managing Microsoft Secure Score Quiz5q
- Reviewing and Responding to Incidents
- Reviewing and Responding to Incidents Quiz5q
- Using Advanced Hunting in Defender XDR
- Using Advanced Hunting in Defender XDR Quiz5q
- Reviewing Defender XDR Reports
- Reviewing Defender XDR Reports Quiz5q
- Using Microsoft Defender Threat Intelligence
- Using Microsoft Defender Threat Intelligence Quiz5q
- Configuring Custom Detection Rules
- Configuring Custom Detection Rules Quiz5q
- Implementing Threat Policies in Defender for Office 365
- Implementing Threat Policies in Defender for Office 365 Quiz5q
- Configuring Alert Policies
- Configuring Alert Policies Quiz5q
- Investigating Email and Collaboration Threats
- Investigating Email and Collaboration Threats Quiz5q
- Managing Attack Simulation Training
- Managing Attack Simulation Training Quiz5q
- Managing Restricted Entities
- Managing Restricted Entities Quiz5q
- Onboarding Devices to Defender for Endpoint
- Onboarding Devices to Defender for Endpoint Quiz5q
- Configuring Endpoint Settings
- Configuring Endpoint Settings Quiz5q
- Using Vulnerability Management Dashboard
- Using Vulnerability Management Dashboard Quiz5q
- Responding to Endpoint Vulnerabilities
- Responding to Endpoint Vulnerabilities Quiz5q
- Managing Automated Investigation and Remediation
- Managing Automated Investigation and Remediation Quiz5q
- Configuring App Connector for Microsoft 365
- Configuring App Connector for Microsoft 365 Quiz5q
- Configuring Cloud Apps Policies
- Configuring Cloud Apps Policies Quiz5q
- Interpreting Activity Logs
- Interpreting Activity Logs Quiz5q
- Configuring Cloud App Discovery
- Configuring Cloud App Discovery Quiz5q
- Responding to Cloud App Discovery Issues
- Responding to Cloud App Discovery Issues Quiz5q
- Implementing Sensitive Information Types
- Implementing Sensitive Information Types Quiz5q
- Using Keywords and Regular Expressions
- Using Keywords and Regular Expressions Quiz5q
- Implementing Retention Labels and Policies
- Implementing Retention Labels and Policies Quiz5q
- Implementing Sensitivity Labels and Policies
- Implementing Sensitivity Labels and Policies Quiz5q
- Monitoring Label Usage with Content Explorer
- Monitoring Label Usage with Content Explorer Quiz5q
- Using Activity Explorer and Label Reports
- Using Activity Explorer and Label Reports Quiz5q
- Configuring Auto-Labeling Policies
- Configuring Auto-Labeling Policies Quiz5q
- Configuring DLP Policies for Exchange Online
- Configuring DLP Policies for Exchange Online Quiz5q
- Configuring DLP for SharePoint and OneDrive
- Configuring DLP for SharePoint and OneDrive Quiz5q
- Configuring DLP for Teams and Power BI
- Configuring DLP for Teams and Power BI Quiz5q
- Configuring DLP for Microsoft 365 Copilot
- Configuring DLP for Microsoft 365 Copilot Quiz5q
- Configuring Endpoint DLP
- Configuring Endpoint DLP Quiz5q
- Reviewing DLP Alerts and Events
- Reviewing DLP Alerts and Events Quiz5q
- Responding to DLP Reports
- Responding to DLP Reports Quiz5q
Spend your points to unlock exam-style practice questions
Spend points to unlock MS-102 exam-style practice questions.
Practice for MS-102