# RemoveNavMeshData(NavMeshDataInstance)

> Removes the specified NavMeshDataInstance from the game, making it unavailable for agents and queries.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine.AI](/engine/6000.6/script-reference/unityengine/ai.md)
* **Assembly:** UnityEngine.AIModule

```csharp
public static void RemoveNavMeshData(NavMeshDataInstance handle)
```

### Parameters

**** (\[NavMeshDataInstance]\(/engine/6000.6/script-reference/unityengine/ai/navmeshdatainstance)): The instance of a NavMesh to remove.

### Remarks

Use the instance returned by [NavMesh.AddNavMeshData](/engine/6000.6/script-reference/unityengine/ai/navmesh/addnavmeshdata.md) to remove the corresponding NavMesh data. If the instance is not valid, e.g. has been removed before, the call has no effect.

Additional Resources: [NavMeshDataInstance.Remove](/engine/6000.6/script-reference/unityengine/ai/navmeshdatainstance/remove.md), [NavMesh.RemoveAllNavMeshData](/engine/6000.6/script-reference/unityengine/ai/navmesh/removeallnavmeshdata.md)
