# GetSceneByPath(string)

> Searches all Scenes loaded for a Scene that has the given asset path.

## Definition

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

```csharp
public static Scene GetSceneByPath(string scenePath)
```

### Parameters

**** (\[string]\(https\://learn.microsoft.com/dotnet/api/system.string)): Path of the Scene. Should be relative to the project folder. Like: "Assets/MyScenes/MyScene.unity".

### Returns

| Type                                                                          | Description                                                               |
| ----------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| [Scene](/engine/6000.6/script-reference/unityengine/scenemanagement/scene.md) | A reference to the Scene, if valid. If not, an invalid Scene is returned. |
