<!--
{
  "documentType" : "article",
  "framework" : "USD",
  "identifier" : "/documentation/USD/autoplay",
  "metadataVersion" : "0.1.0",
  "role" : "article",
  "title" : "autoPlay"
}
-->

# autoPlay

Metadata that specifies whether an animation plays automatically on load.

## Discussion

Set the [autoPlay](/documentation/USD/autoplay) metadata on the document’s *stage*, that is, the outermost container for scene description. For more information about setting stage metadata, see [UsdStage](https://openusd.org/docs/api/class_usd_stage.html) > Stage Metadata.

Set a value of `true` to play an animation automatically when the scene loads. If this property is `false`, the animation won’t play on load. If an asset omits the `autoPlay` property, the animation plays on load for backward-compatibility.

To support assets that disable `autoPlay`, an app should provide a way to start the animation. For example, when an asset sets `autoPlay` to `false`, AR Quick Look displays a scrubber and a Play button the user can tap to start the animation.

Reality Composer sets this property to `false` when it exports a USDZ to enforce that only behaviors ([Preliminary_Behavior](/documentation/USD/preliminary-behavior)) drive animations.

### Declaration

```other
bool autoPlay
```

### Disable automatic animation playback

The following asset demonstrates [autoPlay](/documentation/USD/autoplay) alongside existing animation properties, like `startTimeCode` and `endTimeCode`. Because this asset defines [autoPlay](/documentation/USD/autoplay) as `false`, the runtime doesn’t automatically play the animation after it loads this asset.

```other
#usda 1.0
(
    endTimeCode = 300
    startTimeCode = 1
    timeCodesPerSecond = 30
    autoPlay = false
    upAxis = "Y"
)

def Xform "AnimatedModel"
{
    def Xform "body"
    {
        double3 xformOp:translate.timeSamples = { ... }
        uniform token[] xformOpOrder = ["xformOp:translate"]
        ...
    }
    ...
}
```

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)