# Detach a Server or NIC from a Network Security Group

You can detach a server or Network Interface Card (NIC) from an NSG if its security policies are no longer needed.

To remove a server or NIC from an NSG , follow these steps:

1\. In the **DCD**, go to **Menu** > **Virtual Data Centers** and select the data center from **My Virtual Data Centers**.

2\. Depending on whether you want to detach a server or NIC from an NSG, perform the following action:

{% tabs %}
{% tab title="Detach a Server from an NSG" %}
1\. In the Inspector pane, select the data center and go to the **Settings** tab.

2\. Under the **Network Security Groups**, click **Delete**![Delete icon](/files/yeG91JD4fXnGu5PgptWg) next each NSG.

3\. In the confirmation message, select OK.

![Detach a Server from an NSG](/files/3BldHoLNlrnZAMWAOmNi)
{% endtab %}

{% tab title="Detach an NIC from an NSG" %}
1\. In the Inspector pane, select the data center and go to the **Network** tab.

2\. Open the properties of the NIC for which you want to remove an NSG.

3\. Under the **Network Security Groups**, click **Delete**![Delete icon](/files/yeG91JD4fXnGu5PgptWg) next each NSG.

![Detach an NIC from an NSG](/files/3yNB9DT9WgXlmxopopHr)
{% endtab %}
{% endtabs %}

3\. Provision your changes.

{% hint style="success" %}
**Result:** This action removes a server or an NIC associated with that NSG.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.ionos.com/cloud/security/network-security-groups/how-tos/detach-nsgs.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
