How to enable a computer object in Active Directory

Last updated on:

A computer object in Active Directory (AD) stores the account details for a domain-joined device, including its name, security identifier (SID), and trust relationship with the domain. When a computer object is disabled, the device can no longer be authenticated via Kerberos and loses access to domain resources—this commonly happens after a machine is re-imaged, decommissioned, or removed from the domain and later rejoined.

Enabling a disabled computer object restores the device's ability to be authenticated against the domain. The account's enabled or disabled state is stored in the underlying userAccountControl attribute in AD. This page covers how to enable a computer object using PowerShell's Enable-ADAccount cmdlet, Active Directory Users and Computers (ADUC), Active Directory Administrative Center (ADAC), and ADManager Plus.

  • PowerShell
  • ADUC
  • ADManager Plus
  • Native tools limitations
  • Why ADManager Plus
  • FAQs
 

Prerequisites

  • Permissions: The account running the cmdlet needs Write permissions on computer objects—typically available to members of the Domain Admins and Account Operators groups as well as accounts with delegated control over the relevant OU.
  • Tools: Remote Server Administration Tools (RSAT) must be installed on the machine where you intend to run PowerShell. ADUC and ADAC are also installed as part of RSAT.
  • Module: Import the AD module before running the cmdlet:
Import-Module ActiveDirectory

Steps to enable a computer object using PowerShell

  1. Open PowerShell as an administrator.
  2. If the AD module isn't already available, install RSAT for your Windows version, then import the module:
    Import-Module ActiveDirectory
  3. Run the following command to enable a computer object, replacing JohnS-1001 with the target computer's sAMAccountName, distinguished name (DN), globally unique identifier (GUID), or SID:
    Enable-ADAccount -Identity "JohnS-1001"

Example 1: Enable a computer object by its DN

This identifies the target computer account by its full LDAP path rather than the sAMAccountName:

Enable-ADAccount -Identity "CN=JohnS-1001,OU=Workstations,DC=example,DC=com"

Example 2: Enable all disabled computers in an OU in bulk

This retrieves all disabled computers in a specific OU and passes them through the pipeline to Enable-ADAccount:

Get-ADComputer -Filter {Enabled -eq $false} -SearchBase "OU=Workstations,DC=example,DC=com" | Enable-ADAccount

Example 3: Enable computers from a CSV file in bulk

This reads a CSV file containing a sAMAccountName column and enables each listed computer account:

Import-Csv -Path "C:\computers.csv" | ForEach-Object { Enable-ADAccount -Identity $_.sAMAccountName }

Example 4: Preview changes before enabling objects in bulk

This runs the operation in simulation mode using -WhatIf to show which accounts would be affected without making any changes:

Get-ADComputer -Filter {Enabled -eq $false} -SearchBase "OU=Workstations,DC=example,DC=com" | Enable-ADAccount -WhatIf

Example 5: Enable a computer in a remote domain

This uses the -Server parameter to target a domain controller (DC) in a remote domain, with alternate credentials supplied via -Credential:

Enable-ADAccount -Identity "JohnS-1001" -Server "dc01.remotedomain.com" -Credential (Get-Credential)

Supported parameters

Parameter Description
-Identity Specifies the computer account to enable—accepts the sAMAccountName, DN, GUID, or SID
-Credential Runs the cmdlet under alternate credentials when the current account lacks sufficient permissions
-Server Specifies a DC or Active Directory Domain Services instance to connect to—useful when targeting a specific DC or a remote domain
-PassThru Returns the enabled account object so you can verify it or pipe the result to another command
-WhatIf Simulates the operation and shows which accounts would be affected without making any changes

Steps to enable a computer object using ADUC

  1. Open ADUC (dsa.msc).
  2. In the console tree, expand the domain and navigate to the OU containing the disabled computer account.
  3. Right-click the computer account and select Enable Account.
  4. Click OK on the confirmation prompt.

Note: The Enable Account option appears in the context menu only when the selected computer account is currently disabled.

Steps to enable a computer object using ADAC

  1. Open ADAC (dsac.exe).
  2. Navigate to the OU containing the disabled computer account or use the global search bar to locate it.
  3. Right-click the computer account and select Enable.
  4. Click OK to confirm.

Note: ADAC enables one computer account at a time through this path. There is no bulk selection or bulk enablement option available in ADAC.

Steps to enable a computer object using ADManager Plus

  1. Log in to ADManager Plus and navigate to Management > Computer Management > Enable/Disable Computers.
  2. From the Enable/disable the account drop-down, select Enable.
  3. From the Select Domain drop-down, select the domain where the target computers are located. To restrict the scope to a specific OU, click Add OUs and select the appropriate OU.
  4. To specify which computers to enable, use one of the following methods:
    • CSV Import: Click CSV Import, upload a file containing the list of computer names, then select the relevant LDAP attribute from the drop-down on the right.
    • Search: Click Search to list all computers in the selected domain or OU, or use Enter name(s) to search to filter the results.
  5. Use the check boxes to select the desired computers and click Apply.

ADManager Plus displays a change summary and the status of each operation after the action is completed.

Troubleshooting

1. Error: Cannot find an object with identity: 'ComputerName' under: 'DC=example,DC=com'

The value passed to -Identity does not match any account in the directory. Verify the computer's sAMAccountName by running Get-ADComputer -Filter {Name -eq "ComputerName"}. Computer sAMAccountNames in AD include a trailing dollar sign (for example, JohnS-1001$), though Enable-ADAccount also accepts the name without it.

2. Error: Access is denied

The account running the cmdlet does not have Write permissions on the target computer object. Run PowerShell as an account with Domain Admin or Account Operator privileges, or confirm that delegated rights have been granted for the relevant OU.

3. Error: The server is not operational

PowerShell cannot reach a DC. Verify network connectivity and DNS resolution and confirm that Active Directory Web Services is running on the target DC. If needed, specify an available DC using the -Server parameter.

4. Error: The term 'Enable-ADAccount' is not recognized as the name of a cmdlet

The AD module is not loaded in the current session. Run Import-Module ActiveDirectory before using the cmdlet. If the module is unavailable, install RSAT for your Windows version first.

5. The cmdlet completes without an error but the account remains disabled

Run the following:

Get-ADComputer -Identity "JohnS-1001" -Properties Enabled

Check the current state. If it still shows as Enabled: False, confirm that AD replication has been completed across DCs and check whether any ACL restriction is blocking the modification on the target object.

Limitations of using native tools to enable computer objects

  • ADUC handles one computer account at a time and provides no bulk enablement option.
  • ADAC also lacks a bulk selection option; enabling multiple accounts requires repeating the process for each account.
  • Bulk enablement via PowerShell requires custom scripting for CSV processing and error handling, with no built-in rollback or change summary.
  • Neither ADUC nor ADAC logs the action or generates a change report after enabling accounts.
  • Delegating the enablement task in native AD requires careful ACL configuration or a broad group membership; there is no simplified delegation path for help desk staff.

How ADManager Plus streamlines enabling computer objects

ADManager Plus makes AD management easier and faster through a single, intuitive console. Here’s why it’s a better choice for IT teams:

  • Computer management: AdManager Plus centralizes enable, disable, move, and delete actions for computer accounts in a single web-based module with no scripts required.
  • Bulk enablement: Select and enable multiple computer accounts in one operation through a search or CSV import in the console, with a built-in change summary.
  • CSV importing: The built-in import option accepts a CSV file of computer names and processes all accounts at once, removing the need to write and test bulk scripts.
  • Help desk delegation: Grant help desk technicians permission to enable computer accounts without assigning them Domain Admin or Account Operator rights in AD.
  • Computer reports: Purpose-built reports for disabled, inactive, and all computer accounts provide account status visibility without additional queries or scripts.
  • Automation: Routine computer management tasks can be scheduled and automated to reduce manual intervention.

FAQs

Both achieve the same result by updating the userAccountControl attribute on the computer object. Enable-ADAccount works across all AD account types—users, computers, and service accounts—using the same syntax. Set-ADComputer is specific to computer objects. Both approaches are valid; Enable-ADAccount is typically shorter and more portable when working across mixed account types.

Yes. Use the -Server parameter to specify a DC in the target domain, then provide alternate credentials with -Credential if the current account does not have rights in that domain:

Enable-ADAccount -Identity "JohnS-1001" -Server "dc01.remotedomain.com" -Credential (Get-Credential)

Run the following command and check the Enabled property in the output. A value of True confirms the account is active.

Get-ADComputer -Identity "JohnS-1001" -Properties Enabled

You need Write permissions on the userAccountControl attribute of the computer object. Domain Admins and Account Operators have this by default. In delegated environments, help desk staff can be granted this specific right over an OU without needing to join either group. ADManager Plus simplifies this delegation through role-based assignment.

Not automatically. Enabling the account in AD restores the account's ability to be authenticated into the domain, but if the device's machine password is out of sync (for example, after re-imaging), the device may also need to be rejoined to the domain to reestablish the trust relationship.

Yes. ADManager Plus lets administrators delegate the enable and disable tasks to help desk technicians through role-based access control. Technicians can enable computer accounts from the ADManager Plus console without holding elevated AD privileges.

Simplify AD bulk management and reporting with ADManager Plus

The one-stop solution to Active Directory Management and Reporting
Email Download Link Email the ADManager Plus download link