Mitch Bartlett Comments (5)
Using a simple command, you can add or remove a Windows computer to a Microsoft Windows domain remotely from another computer.
Add a Computer to the Domain
Execute this command from a domain controller:
- Open a command prompt.
- Type
net computer \\computername /add
, then press “Enter“.
Execute this command from a workstation where you have domain admin rights. Change the words in italics to suit your situation:
netdom join computername /domain:domainname
Remove a Computer from the Domain
Execute this command from a domain controller:
- Open a command prompt.
- Type
net computer \\computername /del
, then press “Enter“.
Execute this command from a workstation where you have domain admin rights. Change the words in italics to suit your situation:
netdom removecomputername /domain:domainname
These command are especially valuable if you are using batch files.
Author Mitch Bartlett
Through my career that spans over 20 years I have become an expert in Microsoft Systems Administration, Android, and macOS. I started this site as a technical guide for myself and it has grown into what I hope is a useful knowledgebase for everyone.