> For the complete documentation index, see [llms.txt](https://docs.ionos.com/cloud/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ionos.com/cloud/home/containers/managed-kubernetes/how-tos/remove-taint.md).

# Remove a Taint

Remove taints from IONOS CLOUD Managed Kubernetes node pools or individual nodes with the DCD, IONOS CLOUD API, Terraform, or kubectl.

Remove a taint when you no longer want it to repel workloads from the nodes, such as when a maintenance window ends, when a workload no longer requires dedicated nodes, or when you finish testing. After you remove a taint, the scheduler can assign pods without a matching toleration to the node again. Remove a taint at the same level where you added it:

* **Node pool level:** Remove the taint from the node pool specification. The change applies to all nodes in that pool.
* **Individual node level:** Remove the taint from a single node with `kubectl`. The change applies only to that node.

{% hint style="info" %}
**Prerequisites:** Before you begin, ensure you have the following:

* A node pool or node with at least one taint. For more information, see [<mark style="color:blue;">Configure Taints and Tolerations</mark>](/cloud/home/containers/managed-kubernetes/how-tos/configure-node-pool-taints.md).
* `kubectl` installed and configured to access your cluster.
  {% endhint %}

{% hint style="warning" %}
**Important:** Leave the taints that Kubernetes manages in place. For more information, see [<mark style="color:blue;">System taints</mark>](/cloud/home/containers/managed-kubernetes/overview/taints-and-tolerations.md#system-taints).
{% endhint %}

## Remove a taint from a node pool

{% tabs %}
{% tab title="DCD" %}

1. In the **DCD**, go to **Menu** > **Containers** > **Managed Kubernetes**.
2. Select a cluster from the list and go to the **Node pools in Cluster** tab.
3. Select the node pool you want to update.
4. In the **Advanced settings** section, go to **Taints**. Select the **x** next to each taint you want to remove.

![Remove a taint from the node pool](https://1737632334-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MifAzdGvKLDTtvJP8sm%2Fuploads%2Fgit-blob-6bc06e3a3250277e459c9d66c9a068a38c74f6d2%2Fkubernetes-remove-taint.webp?alt=media)

5. Select **Edit node pool** to save your changes.
   {% endtab %}

{% tab title="IONOS CLOUD API" %}
To remove all taints from a node pool using the <code class="expression">space.vars.ionos\_cloud\_api</code>, set the `taints` array to an empty array:

```bash
curl -X PUT \
  "https://api.ionos.com/cloudapi/v6/k8s/CLUSTER_ID/nodepools/NODEPOOL_ID" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "properties": {
      "nodeCount": NODE_COUNT,
      "taints": []
    }
  }'
```

Replace `CLUSTER_ID`, `NODEPOOL_ID`, `YOUR_API_TOKEN`, and `NODE_COUNT` with your values. `NODE_COUNT` is the current number of nodes in the node pool. The `nodeCount` property is required in every update request.

To remove a specific taint, send the full `taints` array without the taint you want to remove.
{% endtab %}

{% tab title="Terraform" %}

1. In the `ionoscloud_k8s_node_pool` resource, delete the `taints` block for each taint you want to remove.
2. Apply the configuration:

   ```bash
   terraform apply
   ```

{% endtab %}
{% endtabs %}

To verify that the taints are removed from the nodes in the pool, run the following command after the node pool reaches the **Available** state:

```bash
kubectl get nodes -o custom-columns='NAME:.metadata.name,TAINTS:.spec.taints'
```

The `TAINTS` column no longer lists the removed taints.

## Remove a taint from an individual node

To remove a taint, append `-` to the taint specification.

{% hint style="info" %}
**Note:** If the taint comes from the node pool, it returns on the node the next time the node pool is updated. To remove it permanently, remove it from the node pool. For more information, see [<mark style="color:blue;">Remove a taint from a node pool</mark>](#remove-a-taint-from-a-node-pool).
{% endhint %}

1. Remove the taint by `key`, `value`, and `effect`. If you do not know the exact value, remove it by `key` and `effect` only:

   ```bash
   # Remove by key, value, and effect
   kubectl taint nodes NODE_NAME key=value:NoSchedule-

   # Remove by key and effect only
   kubectl taint nodes NODE_NAME key:NoSchedule-
   ```
2. Verify the taint was removed:

   ```bash
   kubectl describe node NODE_NAME | grep Taints
   ```

   If no taints remain, the output shows:

   ```
   Taints:   <none>
   ```

## Next steps

* [<mark style="color:blue;">Configure Taints and Tolerations</mark>](/cloud/home/containers/managed-kubernetes/how-tos/configure-node-pool-taints.md)
* [<mark style="color:blue;">Taints and tolerations overview</mark>](/cloud/home/containers/managed-kubernetes/overview/taints-and-tolerations.md)
* [<mark style="color:blue;">Kubernetes Documentation about Taints and Tolerations</mark>](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/)
* [<mark style="color:blue;">Manage Node Pools</mark>](/cloud/home/containers/managed-kubernetes/how-tos/management-of-node-pools.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.ionos.com/cloud/home/containers/managed-kubernetes/how-tos/remove-taint.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
