# sleepingAllowed

> Controls if bodies go to sleep when not moving and not interacting. Sleeping can provide a significant performance improvement when many Dynamic or Kinematic bodies are in the world. See _sleepingAllowed

## Definition

* **Type:** Property
* **Namespace:** [Unity.U2D.Physics](/engine/6000.6/script-reference/unity/u2d/physics.md)
* **Assembly:** UnityEngine.PhysicsCore2DModule

```csharp
public bool sleepingAllowed { readonly get; set; }
```
