---
title: "Enable DNSSEC on domain"
method: GET
path: "/enable_dnssec_for_domains"
tags: ["DNS", "DNS Security"]
---

# Enable DNSSEC on domain

`GET /enable_dnssec_for_domains`

This function enables DNSSEC on the domain.

**Note:**

* Only servers that run PowerDNS can use DNSSEC. If you call this function on a server that doesn't use PowerDNS, you will receive an error.
* After you enable DNSSEC on the domain, you **must** add the Delegation of Signing (DS) records on your DNS server and with your registrar.
* You **cannot** modify the DNSSEC security key. To make any changes, you **must** disable, delete, and re-create the DNSSEC security key.

## Query parameters

- `domain` string, domain, required
- `active` 0 | 1
- `algo_num` 5 | 6 | 7 | 8 | 10 | 13 | 14
- `key_setup` 'classic' | 'simple'
- `nsec3_iterations` integer
- `nsec3_narrow` 0 | 1
- `nsec3_opt_out` 0 | 1
- `nsec3_salt` string
- `use_nsec3` 0 | 1

## Response `200`

HTTP Request was successful.

- object
  - `data` object
    - `domains` object[] — An array of objects that contains information about each domain.
      - `domain` string, domain — The domain for which the system enabled DNSSEC.
      - `enabled` 0 | 1 — Whether the system enabled DNSSEC. * `1` - Enabled. * `0` - The system failed to enable DNSSEC. **Note:** This function will **not** return the `nsec_version` and `new_key_id` returns if this return is a `0` value.
      - `new_key_id` string — The assigned security key ID. A valid ID.
      - `nsec_error` string — The domain has a NSEC3 configuration error. **Note:** The function **only** displays this return if there is a NSEC3 configuration error. An error message.
      - `nsec_version` 'NSEC3' | 'NSEC' — The version of DNSSEC the system used. * `NSEC3` * `NSEC` **Note:** The function only displays this return if there is a NSEC3 configuration error. The system also returns the error in the `nsec_error` return.
  - `metadata` object
    - `command` string — The method name called.
    - `reason` string — The reason the API function failed when the `metadata.result` field is `0`. This field may display a success message when a function succeeds.
    - `result` 0 | 1 — * `1` - Success. * `0` - Failed. Check the `reason` field for more details.
    - `version` integer — The version of the API function.

---

[API](https://skmtc.net/cpanel/apis/whm-api.md) · [All operations](https://skmtc.net/cpanel/apis/whm-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cpanel/whm-api/revisions/3da41671c02c/schema)
