/
/

How MSPs Can Identify and Manage Unused Devices Without Dedicated Inventory Tools

by Lauren Ballejos, IT Editorial Expert
How MSPs Can Identify and Manage Unused Devices Without Dedicated Inventory Tools blog banner image
How MSPs Can Identify and Manage Unused Devices Without Dedicated Inventory Tools blog banner image

Key points

  • Detecting unused devices helps reclaim hardware, save on software licenses, and eliminate security risks from unpatched systems.
  • Identify stale devices using PowerShell scripts that query Microsoft Entra ID (Azure AD) and Active Directory, without relying on dedicated inventory tools.
  • Define clear inactivity thresholds, such as 60-90 days without a sign-in, tailored to your organization’s needs.
  • Automating the script execution and reporting, potentially with an RMM tool, streamlines the ongoing process of finding unused devices.
  • To prevent data loss, disable or move unused devices first, rather than immediately deleting them, to allow for a safe recall period.

This guide demonstrates how to manage unused devices without dedicated inventory tools for your organization, or in MSP client environment. This allows you to identify underutilized and stale devices, freeing up hardware for use. Identifying unused devices also ensures that software licenses and subscriptions are not wasted and prevents them from becoming a security vulnerability due to a lack of updates and oversight.

Instructions are provided for using PowerShell to query Microsoft Entra ID and Intune, as well as Active Directory (AD), to find unused devices without dedicated third-party inventory software.

Track unused devices, licenses, and warranties in a single inventory.

💻 See what NinjaOne ITAM can do.

Why you need to detect unused devices in the enterprise

IT teams and managed service providers (MSPs) should regularly scan for unused devices so that they can be recalled or re-assigned to other users. Unused (or ‘stale’) devices increase costs, consuming software licenses and support or warranty contracts with no productivity benefit. They also pose an ongoing security and compliance risk, as they will remain unpatched against the latest threats if they have been offline for a significant amount of time.

While many ITSM and MSP tools include inventory scanning and management, smaller organizations or those still deciding on which platform they’ll base their IT management on may want a lightweight solution for detecting unused devices that doesn’t require third-party tools.

What you need before you start

To perform the steps in this guide, you’ll need the following:

  • Admin access to client AD or Azure AD environments
  • PowerShell and basic proficiency with PowerShell scripting
  • A secure repository for report storage (for example, SharePoint, IT Glue, or NinjaOne Docs)
  • Agreement with client stakeholders on thresholds for “inactive” devices
  • Optional remote monitoring and management (RMM), such as NinjaOne, for scheduled script execution and reporting

Step #1. Define your criteria for an unused device

Before you can tailor the example scripts below to detect unused devices, you must define the criteria for a device to be considered stale. This will depend on your organization (or client, if you’re an MSP): some organizations will expect devices to be seen online more regularly than others, and there may be classes of devices that are expected to be offline for longer periods, for example, devices used by roaming employees, or spare devices that may need to be periodically brought online for updates.

Frequently used criteria for an inactive device include:

  • No sign-in or activity in 60–90 days
  • Devices still registered, but offline/stale in AD or Entra ID
  • Orphaned AD computer objects (i.e., with no last logon)
  • Missing RMM agent check-ins beyond SLA

Step #2. Detect inactive devices in Entra ID via PowerShell

Once you have established these criteria, you can tailor and extend the PowerShell scripts below to automate the detection of unused devices.

Finding unused devices using Microsoft Entra (Azure AD / Intune):

Connect-Entra -Scopes “Device.Read.All”

$threshold = (Get-Date).AddDays(-90)

Get-EntraDevice -All | Where-Object { $_.ApproximateLastSignInDateTime -le $threshold } |

Select DisplayName, ApproximateLastSignInDateTime |

Export-Csv .\stale-devices.csv -NoTypeInformation

Finding unused devices using Active Directory:

$days = 90

$time = (Get-Date).AddDays(-$days)

Get-ADComputer -Filter {LastLogonTimeStamp -lt $time} -Properties LastLogonDate |

Select Name, LastLogonDate |

Export-Csv .\inactive-computers.csv -NoTypeInformation

You can then add other criteria specific to your use case.

Step #3. Consolidate, automate, and report findings

Once you have generated CSV data listing unused devices using PowerShell scripting, you can store it in a consistent format for later reporting. For example, you may store this information in the following format:

ClientDevice NameLast ActivityStatusRecommendation
Client ALT-10292024-05-12Inactive > 90dDisable
Client BWS-20452025-01-05ActiveRetain

You can then upload this data to a secure location and leverage analysis and reporting tools like Excel or Power BI to track the status of unused devices.

Automation eliminates the recurring task of identifying stale devices, allowing you to receive generated reports that indicate which devices need to be removed, wiped, or recalled. This can be done using Windows’ built-in scheduling tools or using your RMM platform to take inventory, generate reports, and send alerts. RMM with integrated ticketing can also automatically create tickets when thresholds are exceeded to ensure support action is taken promptly.

Best practices for managing stale devices in MSP environments

To prevent data loss and prevent devices from unintentionally becoming unmanaged, avoid immediately deleting devices that are detected as unused or inactive. Instead, they should be moved into a separate organizational unit for tracking. Then any permissions or access granted to the device (and optionally, the user account of its primary user if that is also inactive) are revoked. If the device was erroneously marked inactive, the user will no doubt notify you of the mistake once they can no longer use it. After a set period of time (for example, 30-60 days), the device can then be fully removed from your systems if it has not been seen, recalled, or reassigned.

MSPs should integrate reporting on unused devices into quarterly business reviews (QBRs), presenting stale device trends, validating current thresholds, and agreeing on what to do with detected devices.

The lightweight stale-device detection methods described in this article provide the following benefits, following best practices:

ComponentValue Provided
Clear inactivity thresholdsPrevents misclassification and disputes
PowerShell-based detectionWorks across AD and Entra without extra tools
Consolidated reportingProvides MSP-wide visibility and trends
Automated alertsReduces manual checks, accelerates cleanup
Disable-first workflowAvoids accidental data loss
Governance reviewsMaintains audit trail and client accountability

Whenever an unused device is identified or removed, you should ensure that asset records and support tickets are updated with the decision and final action.

Automatically detect unused hardware without using multiple tools.

➤ Sign up for a 14-day free trial of NinjaOne.

NinjaOne automates device inventory, helps you track down unused devices, and improves IT cost efficiency

The NinjaOne suite of IT and MSP tools includes RMM, mobile device management (MDM), and endpoint management with built-in hardware and software inventory and automated reporting. You can filter devices by status, type, and role, as well as add custom fields and tag devices for quick differentiation. This can be done for a single organization or across tenants for MSPs.

NinjaOne also lets you deploy PowerShell scripts via policies to collect additional device data and determine whether devices are fully utilized, and to create automated alerts and tickets when devices breach defined thresholds. You can send consolidated information to NinjaOne Docs for long-term evaluation, and embed unused device metrics in your QBR dashboards for client visibility.

Many MSPs choose RMM platforms with built-in inventory rather than relying on heavy, dedicated inventory platforms to detect stale devices and track hardware lifecycles. For those working with small deployments and do not need to scale, PowerShell scripting offers a workable, lightweight alternative.

Quick-Start Guide

NinjaOne offers several capabilities to help MSPs identify and manage unused devices:

1. IT Asset Management (ITAM) App:
– NinjaOne has an ITAM feature that allows tracking of devices that are not natively supported, such as:
– Phones outside MDM support
– Cameras
– Printers
– You can create custom device types using custom fields
– Currently in early access, so feedback is welcome

2. Unmanaged Device Management:
– Ability to add and track unmanaged devices
– Provides a dashboard with limited information about unmanaged devices
– Includes tabs for:
– Overview
– Activities
– Custom Ticketing
– Settings

3. Device Roles and Tracking:
– Create custom device roles
– Assign default policies to device roles
– Track device information through custom fields
– Manage device lifecycle

4. Warranty Information:
– Can add columns for Warranty Start and End Dates in the Devices Search Grid
– Set warranty dates in device dashboards

These features provide MSPs with tools to identify, track, and manage devices that might otherwise go unnoticed, helping to maintain a comprehensive inventory and potentially reduce unused or unnecessary assets.

FAQs

Unused devices waste money by continuing to consume software licenses, subscriptions, and warranty or support contracts with no productivity benefit in return. They also pose an ongoing security risk, since devices that haven’t been online recently are likely missing critical patches and updates, making them an easy target if reconnected to the network.

No, this guide shows how to use built-in PowerShell scripts to query Microsoft Entra ID and Active Directory directly, without dedicated third-party tools.

There’s no universal standard. You need to define your own inactivity threshold based on how devices are typically used. A common starting point is 60 to 90 days without a sign-in, though this should be adjusted for device classes like roaming employee laptops or spare equipment that may legitimately go offline for extended periods.

Yes, the provided PowerShell scripts can be scheduled to run automatically using Windows Task Scheduler or an RMM platform, which can then generate reports and alerts.

The main risk is accidentally deleting a device that is still needed, which is why the guide recommends disabling it or moving it to a separate OU before immediate deletion.

MSPs should integrate the findings into Quarterly Business Reviews (QBRs) to show trends, validate inactivity thresholds, and agree on actions for the unused devices.

Run Install-Module -Name Microsoft.Entra -Scope CurrentUser from an elevated PowerShell session to install the current module.

You might also like

Ready to simplify the hardest parts of IT?