# GetBuildIndexByScenePath(string)

> Get the build index from a Scene path.

## Definition

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

```csharp
public static int GetBuildIndexByScenePath(string scenePath)
```

### Parameters

**** (\[string]\(https\://learn.microsoft.com/dotnet/api/system.string)): Scene path (e.g: "Assets/Scenes/Scene1.unity").

### Returns

| Type                                                       | Description  |
| ---------------------------------------------------------- | ------------ |
| [int](https://learn.microsoft.com/dotnet/api/system.int32) | Build index. |

### Remarks

The build index refers to the index into the list of Scenes as specified in the Build Settings window.

If the scene isn't found it returns -1.
