> For the complete documentation index, see [llms.txt](https://doc.traceye.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://doc.traceye.io/services/dedicated-indexing/graph-nodes/subgraph-manual/manage-subgraph.md).

# Manage Subgraph

This section will guide you on how to manage a subgraph.

* [Create Subgraph](#create-subgraph)
* [Deploy Subgraph](#deploy-subgraph)
* [Query Subgraph](#query-subgraph)
* [Delete Subgraph](#delete-subgraph)

***

### Create Subgraph

{% hint style="warning" %}
The node needs to be in the live state for you to add a subgraph to it.
{% endhint %}

**Step 1: Graph Nodes** - Navigate to the [Graph Nodes](https://app.traceye.io/subgraph/graph-node) page on the platform. Here you will see a list of nodes that you purchased and the ones that are already deployed. Now, click on the **Add Subgraph** button.

<figure><img src="/files/NpBv1E2mzNsigmM5Aun8" alt=""><figcaption></figcaption></figure>

**Step 2: Create Subgraph -** Choose the **Create New** option from the dropdown menu.

<figure><img src="/files/phiFI3TkhfTszxWfrj9Q" alt=""><figcaption></figcaption></figure>

**Step 3: Enter Details -** Provide a name, and choose the node and the network for your subgraph. Now, click on the **Add** button to create a new subgraph.\
NOTE: If only one node is live then it will be pre-selected. Also, if a single network is present in the node then it will also be pre-selected.

<figure><img src="/files/GEYLW6zkdz6nsWVIa0fs" alt=""><figcaption></figcaption></figure>

On successful creation, you will be redirected to the subgraph detail page.

<figure><img src="/files/axz6AVbmbQcCcdHPR0y4" alt=""><figcaption></figcaption></figure>

***

### Deploy Subgraph

**Step 1:** Navigate to the **Details** section on the subgraph detail page. Now, click on the **Deployment Command** button.

<figure><img src="/files/xGxYyDYXoC0XZIylYzu3" alt=""><figcaption></figcaption></figure>

**Step 2:** Follow the steps provided on the screen to deploy your own subgraph.

<figure><img src="/files/WPFhS0iHlKpB3G0hzNDy" alt=""><figcaption></figcaption></figure>

***

### Query Subgraph

{% hint style="warning" %}
The subgraph must be deployed and indexed before it can be queried.
{% endhint %}

On the subgraph detail page, navigate to the **Query URL** section. Click on first icon to open the **GraphiQL** query editor on a new tab, or click on second icon to copy the query URL.

<figure><img src="/files/XStZr0TXDQnsjhYTueaM" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/FW0azoxf0XgoXnEsTxr2" alt=""><figcaption></figcaption></figure>

***

### Delete Subgraph

On the subgraph detail page, click on the **Delete** button on the top right corner of the screen.

<figure><img src="/files/e5gk4BMALtqW3NdY0McR" alt=""><figcaption></figcaption></figure>

Now, click on the **Continue** button to delete the subgraph.

<figure><img src="/files/duTkbjamtr1cYMb9n87O" alt=""><figcaption></figcaption></figure>
