Blocks or unblocks inheritance for a specified domain or organizational unit.
Active Directory · Risk: High · Documentation Verified
Last verified: 2026-10-26
Microsoft GroupPolicy reference: Blocks or unblocks inheritance for a specified domain or organizational unit. The syntax and selected example below are adapted from the pinned Windows Server 2025 reference. Module availability, target configuration and delegated permissions determine whether it can run in your environment. Documentation and parameter text: Microsoft, CC BY 4.0; formatting adapted by Cmdlet World. No execution testing is claimed.
Use an account with the target resource permissions documented for Set-GPInheritance. Modifying administrative cmdlets may require elevation or delegated administration. This catalog does not assert that ordinary users can execute the command.
Supported environments
Windows / GroupPolicy · Windows Server 2025 documentation; feature/module prerequisites apply
Parameters
-Confirm
Prompts you for confirmation before running the cmdlet.
-Domain
Specifies the domain for this cmdlet. You must specify the fully qualified domain name (FQDN) of the domain. For the Set-GPInheritance cmdlet, this is typically the domain of the Active Directory container (domain or OU) for which you want to block or unblock inheritance. If the domain for the cmdlet is different than the domain of the container, a trust must exist between the two domains. If you do not specify the Domain parameter, the domain of the user that is running the current session is used. If the cmdlet is being run from a computer startup or shutdown script, the domain of the computer is used. For more information, see the Notes section in the full Help. If you specify a domain that is different from the domain of the user that is running the current session (or, for a startup or shutdown script, the computer), a trust must exist between that domain and the domain of the user or the computer. You can also refer to the Domain parameter by its built-in alias, DomainName. For more information, see about_Aliases.
-IsBlocked (required)
Indicates whether to block inheritance for the domain or OU. You must specify Yes or No. The following values are permitted for this object type.
-Server
Specifies the name of the domain controller that this cmdlet contacts to complete the operation. You can specify either the fully qualified domain name (FQDN) or the host name. If you do not specify the name by using the Server parameter, the primary domain controller (PDC) emulator is contacted. You can also refer to the Server parameter by its built-in alias, DC.
-Target (required)
Specifies the domain or the OU for which to block or unblock inheritance by its LDAP distinguished name. For instance, the MyOU organizational unit in the contoso.com domain is specified as ou=MyOU,dc=contoso,dc=com. You can also refer to the Target parameter by its built-in alias, Path.
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Prerequisites
Windows with the GroupPolicy module and the Windows feature or management tools that provide it. Confirm target connectivity and version compatibility using the linked Microsoft reference.
Security considerations
This cmdlet changes system state. Review every target and parameter in the official reference, test outside production, and prepare an appropriate backup or rollback. Do not execute the example automatically.
This command blocks inheritance for the OU named MyOU in the contoso.com domain. GPOs that are linked to higher-level sites or domains, or to OUs that are parent OUs of the OU named MyOU are not applied, unless their links are enforced, when Group Policy is processed for the OU on the client. Because inheritance is blocked, only GPOs that are linked directly to the MyOU, and those that are enforced at higher-level containers, appear in the InheritedGpoLinks list. Source: Microsoft, CC BY 4.0; transcript prompt/output removed. This example was not executed.