<!--
{
  "availability" : [
    "iOS: 7.1.0 -",
    "iPadOS: 7.1.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.12.2 -",
    "tvOS: 7.1.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 5.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "MediaPlayer",
  "identifier" : "/documentation/MediaPlayer/MPRemoteCommandCenter/togglePlayPauseCommand",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "Media Player"
    ],
    "preciseIdentifier" : "c:objc(cs)MPRemoteCommandCenter(py)togglePlayPauseCommand"
  },
  "title" : "togglePlayPauseCommand"
}
-->

# togglePlayPauseCommand

The command object for toggling between playing and pausing the current item.

```
var togglePlayPauseCommand: MPRemoteCommand { get }
```

## Discussion

Use the object in this property to register your app’s handler for toggling between playing and pausing the current track. In your handler, perform the appropriate task based on the current state of the media item. If the item is currently playing, pause it. If it is paused, resume playing it. You can disable the command if your app does not support it.

---

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)