# GetDepth(in HierarchyNode)

> Determines the depth of a node.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Hierarchy](/engine/6000.6/script-reference/unity/hierarchy.md)
* **Assembly:** UnityEngine.HierarchyCoreModule

## GetDepth(HierarchyNode)

```csharp
public int GetDepth(in HierarchyNode node)
```

### Parameters

**** (\[HierarchyNode]\(/engine/6000.6/script-reference/unity/hierarchy/hierarchynode)): The hierarchy node.

### Returns

| Type                                                       | Description                      |
| ---------------------------------------------------------- | -------------------------------- |
| [int](https://learn.microsoft.com/dotnet/api/system.int32) | The depth of the hierarchy node. |
