Skip to content

PowerShell script to remove devices from Intune and Autopilot in bulk

Notifications You must be signed in to change notification settings

AidanRB/Remove-IntuneDevices

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 

Repository files navigation

Remove-IntuneDevices.ps1

Instructions for setup:

  • Press Windows+X, then click "Windows PowerShell (Admin)" or "Terminal (Admin)"
  • Authenticate as admin
  • Paste in: Set-ExecutionPolicy Unrestricted ; Install-Module Microsoft.Graph ; Install-Module Microsoft.Graph.Intune
  • Close the PowerShell window
  • Download Remove-IntuneDevices.ps1

Instructions for use:

  • Prepare a CSV file with a column named SerialNumber
  • Right click Remove-IntuneDevices.ps1
  • Click Run with PowerShell
  • Follow the prompts
    • To remove devices from Intune, choose the CSV file using the first file picker
    • To remove from Intune, Autopilot, and Azure AD, click Cancel on the first file picker, then choose the CSV file using the second file picker
    • If asked, log in with your Microsoft account and accept the permissions
  • Logs are outputted as a CSV file with the date to the directory of the chosen CSV file

About

PowerShell script to remove devices from Intune and Autopilot in bulk

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published