

# Deactivate third-party public extensions in your account
<a name="registry-public-deactivate-extension"></a>

When you no longer need an activated third-party public extension, use the following procedures to deactivate it in your account.

**Topics**
+ [Deactivate a public extension in your account (console)](#registry-public-deactivate-extension-console)
+ [Deactivate a public extension in your account (Amazon CLI)](#registry-public-deactivate-extension-cli)
+ [Disable a Hook in your account (Amazon CLI)](#registry-public-deactivate-extension-cli-hook)

## Deactivate a public extension in your account (console)
<a name="registry-public-deactivate-extension-console"></a>

**To deactivate a public extension in your account**

1. Sign in to the Amazon Web Services Management Console and open the Amazon CloudFormation console at [https://console.amazonaws.cn/cloudformation](https://console.amazonaws.cn/cloudformation/).

1. On the navigation bar at the top of the screen, choose your Amazon Web Services Region.

1. From the navigation pane, under **Registry**, choose **Activated extensions**.

1. Find the extension you want to deactivate and select it. For more information, see [View the available and activated extensions in the CloudFormation registry](registry-view.md).

1. From the **Actions** menu, choose **Deactivate**.

1. Choose **Deactivate**.

## Deactivate a public extension in your account (Amazon CLI)
<a name="registry-public-deactivate-extension-cli"></a>

Use the following [https://docs.amazonaws.cn/cli/latest/reference/cloudformation/deactivate-type.html](https://docs.amazonaws.cn/cli/latest/reference/cloudformation/deactivate-type.html) command.

```
aws cloudformation deactivate-type --type {{MODULE}} \
  --type-name {{Example::Test::Type::MODULE}} \
  --region {{us-west-2}}
```

## Disable a Hook in your account (Amazon CLI)
<a name="registry-public-deactivate-extension-cli-hook"></a>

Disabling a Hook prevents the Hook from running in your Amazon Web Services account without removing it.

Use the [https://docs.amazonaws.cn/cli/latest/reference/cloudformation/set-type-configuration.html](https://docs.amazonaws.cn/cli/latest/reference/cloudformation/set-type-configuration.html) command and specify `HookInvocationStatus` as `DISABLED` to disable a Hook.

The following example specifies the Amazon Web Services Region and the Amazon Resource Name (ARN) of the Hook that's being disabled.

```
aws cloudformation set-type-configuration \
  --configuration {{"{"CloudFormationConfiguration":{"HookConfiguration":{"HookInvocationStatus": "DISABLED", "FailureMode": "FAIL", "Properties":{}}}}"}} \
  --type-arn {{"arn:aws:cloudformation:us-west-2:123456789012:type/hook/MyTestHook"}} --region {{us-west-2}}
```

For more information, see [Disable and enable Amazon CloudFormation Hooks](https://docs.amazonaws.cn/cloudformation-cli/latest/hooks-userguide/hooks-disable-enable.html) in the *Amazon CloudFormation Hooks User Guide*.