# InstanceIDIsValid(int)

> Returns true if the given instance ID corresponds to a valid Object in memory. The Object could have been deleted or not loaded into memory yet.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine](/engine/6000.7/script-reference/unityengine.md)
* **Assembly:** UnityEngine.CoreModule

> **Warning:**
>
> **Removed.** InstanceIDIsValid is obsolete. Use EntityIdIsValid instead.

```csharp
public static bool InstanceIDIsValid(int instanceId)
```

### Parameters

**** (\[int]\(https\://learn.microsoft.com/dotnet/api/system.int32)):&#x20;

### Returns

| Type                                                          | Description |
| ------------------------------------------------------------- | ----------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) |             |
