Jump to content

Win11 - Remove User - Azure AD

Go to solution Solved by Needfuldoer,
16 minutes ago, ChrisLoudon said:

Is there a way of removing a user / user files from a Windows 11 machine when they don't show up in the Control Panel > Users list?

Deleting the C:\Users\Username folder and the key under HKLM\Software\Microsoft\Windows NT\CurrentVersion\ProfileList that goes with it should remove everything as though that account never logged in.

 

You can do the same thing in a GUI if you run control userpasswords2 as admin from an elevated command prompt. That will present you with a list of all the local and domain accounts that have logged into that particular machine. You can highlight the ones you don't want and click "Remove", which will automatically delete the local files and the key under ProfileList for you. 

 

Just deleting the folder will remove the files, but if that account ever logs in again they'll get the "you're running a temporary account" alert and their files won't persist. (I know that's not relevant in this particular case, but it's a good tool to keep in your back pocket for troubleshooting profile issues. Rename the old C:\Users\Username folder, export and delete the registry key, then have the user log back in. They'll get a fresh profile and you can recover their documents, AppData folders, and anything else that didn't sync with OneDrive.)

Hi guys,

 

Is there a way of removing a user / user files from a Windows 11 machine when they don't show up in the Control Panel > Users list?

 

I have a laptop that's been returned to me from an ex-employee and I'd like to pass it on to someone else.

 

Users in my business all log into their machines via AzureAD with their Office 365 credentials selecting 'Work or School' account. This seems to setup some sort of local profile for them including a C:\Users\UserName folder which I can delete by logging in as me (admin) and deleting it but is there another / cleaner way of doing this?

 

I could just leave it but if the laptop goes through the hands of more employees I'm just going to end up with a computer filled with the old files of long gone staff.

 

Cheers

 

C

 

 

Living Room PC - Lian-Li O11 XL Evo - MSI X870 Tomahawk Mobo - AMD 9800X3D - 32GB DDR5 Ram - RTX 4090 - 2TB Samsung 990Pro NVMe - Antec 1200w PSU - Dual Custom Loop Cooling - GPU cooled with EK Quantum Surface S240 + EK Quantum Surface P360M X-Flow Rads - CPU cooled with EK Quantum Surface X360M Rad

 

Bedroom PC - Hyte Y60 - Intel Core i5 13600k - MSI Pro-A Wifi Z790 Mobo DDR5 - 32GB Ram - RTX 3080ti - 1TB Samsung 990Pro NVMe - Corsair HX1200i PSU - CPU + GPU cooled with Hyte Y60 Corner Distro Plate - EK Coolstream S120 + EK Quantum Surface S360 + EK Quantum Surface X240M

 

Extension PC - Lian Li o11 Dynamic - Intel Core i9 9900k - MSI Meg Ace Z390 Mobo - 16GB Ram - RTX 2080ti - 256GB Samsung NVMe - Corsair AX850 PSU - CPU + GPU cooled with dual EKWB 360 Rads + G1 side EKWB distro plate.

 

Kitchen PC - Thermaltake Tower 100 - Intel Core i7 8086K - Gbyte Z390 I Aorus Pro Wifi Mobo - 16GB Ram - iGPU - 256GB Samsung NVMe - EVGA B5 850W PSU - CPU cooled with dual EK Quantum Surface P120M Rads + Barrow 3-in-1 Block, Res & Pump.

 

Annex - Corsair 250D - Intel Core i7 8700k - Gbyte Z390 I Aorus Pro Wifi Mobo - 16GB Ram - GTX 1080ti - 256GB Samsung NVMe - BeQuiet P11 750 PSU - CPU cooled with EK Coolstream S240 + S120 Rads + EK Pump / Res Combo

 

Office - Corsair 280X - Intel Core i7 4790k - Asrock H97M ITX Mobo  - 16GB Ram - EVGA GTX 980 - Corsair SFXL600 PSU - CPU + GPU cooled with triple EK Coolstream S240s + EK Pump / Res Combo

 

NAS PC - Fractal Node 804 - Intel Core i7 3770k - Asus P8Z77-M Mobo - 16GB Ram - MSI GTX 1660 Ventus - Corsair AX850 PSU - Unraid 21TB Storage Server

 

Living Room AV Setup 5.1.4 - Nvidia Shield - Yamaha RX-A6A - 2 x B&W CM9s2 - 2 x Monitor Audio FX Silvers - 4 x B&W CCM665s - B&W CMCs2 - SVS SB13 Ultra - LG OLED65C1

 

Extension AV Setup - Sonos ARC + Sub (Gen 3) - LG OLED65C6V + Sonos Amp - 5 x Monitor Audio C265s

 

Bedroom AV Setup - Yamaha WXC-50 - 2 x B&W CM1s - Rel Quake - LG OLED42C2.

Link to comment
https://linustechtips.com/topic/1611927-win11-remove-user-azure-ad/
Share on other sites

Link to post
Share on other sites

16 minutes ago, ChrisLoudon said:

Is there a way of removing a user / user files from a Windows 11 machine when they don't show up in the Control Panel > Users list?

Deleting the C:\Users\Username folder and the key under HKLM\Software\Microsoft\Windows NT\CurrentVersion\ProfileList that goes with it should remove everything as though that account never logged in.

 

You can do the same thing in a GUI if you run control userpasswords2 as admin from an elevated command prompt. That will present you with a list of all the local and domain accounts that have logged into that particular machine. You can highlight the ones you don't want and click "Remove", which will automatically delete the local files and the key under ProfileList for you. 

 

Just deleting the folder will remove the files, but if that account ever logs in again they'll get the "you're running a temporary account" alert and their files won't persist. (I know that's not relevant in this particular case, but it's a good tool to keep in your back pocket for troubleshooting profile issues. Rename the old C:\Users\Username folder, export and delete the registry key, then have the user log back in. They'll get a fresh profile and you can recover their documents, AppData folders, and anything else that didn't sync with OneDrive.)

I sold my soul for ProSupport.

Link to post
Share on other sites

10 minutes ago, Needfuldoer said:

Deleting the C:\Users\Username folder and the key under HKLM\Software\Microsoft\Windows NT\CurrentVersion\ProfileList that goes with it should remove everything as though that account never logged in.

 

You can do the same thing in a GUI if you run control userpasswords2 as admin from an elevated command prompt. That will present you with a list of all the local and domain accounts that have logged into that particular machine. You can highlight the ones you don't want and click "Remove", which will automatically delete the local files and the key under ProfileList for you. 

 

Just deleting the folder will remove the files, but if that account ever logs in again they'll get the "you're running a temporary account" alert and their files won't persist. (I know that's not relevant in this particular case, but it's a good tool to keep in your back pocket for troubleshooting profile issues. Rename the old C:\Users\Username folder, export and delete the registry key, then have the user log back in. They'll get a fresh profile and you can recover their documents, AppData folders, and anything else that didn't sync with OneDrive.)

Nice one, thanks buddy.

 

Will mark this as solved.

 

Cheers

Living Room PC - Lian-Li O11 XL Evo - MSI X870 Tomahawk Mobo - AMD 9800X3D - 32GB DDR5 Ram - RTX 4090 - 2TB Samsung 990Pro NVMe - Antec 1200w PSU - Dual Custom Loop Cooling - GPU cooled with EK Quantum Surface S240 + EK Quantum Surface P360M X-Flow Rads - CPU cooled with EK Quantum Surface X360M Rad

 

Bedroom PC - Hyte Y60 - Intel Core i5 13600k - MSI Pro-A Wifi Z790 Mobo DDR5 - 32GB Ram - RTX 3080ti - 1TB Samsung 990Pro NVMe - Corsair HX1200i PSU - CPU + GPU cooled with Hyte Y60 Corner Distro Plate - EK Coolstream S120 + EK Quantum Surface S360 + EK Quantum Surface X240M

 

Extension PC - Lian Li o11 Dynamic - Intel Core i9 9900k - MSI Meg Ace Z390 Mobo - 16GB Ram - RTX 2080ti - 256GB Samsung NVMe - Corsair AX850 PSU - CPU + GPU cooled with dual EKWB 360 Rads + G1 side EKWB distro plate.

 

Kitchen PC - Thermaltake Tower 100 - Intel Core i7 8086K - Gbyte Z390 I Aorus Pro Wifi Mobo - 16GB Ram - iGPU - 256GB Samsung NVMe - EVGA B5 850W PSU - CPU cooled with dual EK Quantum Surface P120M Rads + Barrow 3-in-1 Block, Res & Pump.

 

Annex - Corsair 250D - Intel Core i7 8700k - Gbyte Z390 I Aorus Pro Wifi Mobo - 16GB Ram - GTX 1080ti - 256GB Samsung NVMe - BeQuiet P11 750 PSU - CPU cooled with EK Coolstream S240 + S120 Rads + EK Pump / Res Combo

 

Office - Corsair 280X - Intel Core i7 4790k - Asrock H97M ITX Mobo  - 16GB Ram - EVGA GTX 980 - Corsair SFXL600 PSU - CPU + GPU cooled with triple EK Coolstream S240s + EK Pump / Res Combo

 

NAS PC - Fractal Node 804 - Intel Core i7 3770k - Asus P8Z77-M Mobo - 16GB Ram - MSI GTX 1660 Ventus - Corsair AX850 PSU - Unraid 21TB Storage Server

 

Living Room AV Setup 5.1.4 - Nvidia Shield - Yamaha RX-A6A - 2 x B&W CM9s2 - 2 x Monitor Audio FX Silvers - 4 x B&W CCM665s - B&W CMCs2 - SVS SB13 Ultra - LG OLED65C1

 

Extension AV Setup - Sonos ARC + Sub (Gen 3) - LG OLED65C6V + Sonos Amp - 5 x Monitor Audio C265s

 

Bedroom AV Setup - Yamaha WXC-50 - 2 x B&W CM1s - Rel Quake - LG OLED42C2.

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×