# isPlaying

> Returns true when called in any kind of built Player, or when called in the Editor in Play mode (Read Only).

## Definition

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

```csharp
public static bool isPlaying { get; }
```

### Remarks

In a built Player, this method always returns true.

In the Editor, it returns true if the Editor is in Play mode.

Unity might throw an exception when `Application.isPlaying` is accessed in the class constructor or its value is assigned to a variable.

**Note**: In the Editor for [ScriptableObject](/engine/6000.6/script-reference/unityengine/scriptableobject.md) assets, this property returns false in OnEnable. After reloading the domain, when reloading assemblies, Unity invokes OnEnable on all [ScriptableObject](/engine/6000.6/script-reference/unityengine/scriptableobject.md) instances. This happens before isPlaying is set to true.

Additional Resources: [Application.IsPlaying](/engine/6000.6/script-reference/unityengine/application/isplaying.md), [ExecuteAlways](/engine/6000.6/script-reference/unityengine/executealways.md).

### Examples

```csharp
using UnityEngine;

class Example : MonoBehaviour
{
    void Start()
    {
        if (Application.isPlaying)
        {
            print("In player or playmode");
        }
    }
}
```
