<!--
{
  "availability" : [
    "iOS: 15.0.0 -",
    "iPadOS: 15.0.0 -",
    "macCatalyst: 15.0.0 -",
    "tvOS: 15.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "MusicKit",
  "identifier" : "/documentation/MusicKit/SystemMusicPlayer",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "MusicKit"
    ],
    "preciseIdentifier" : "s:8MusicKit06SystemA6PlayerC"
  },
  "title" : "SystemMusicPlayer"
}
-->

# SystemMusicPlayer

An object your app uses to play music by controlling the Music app’s state.

```
class SystemMusicPlayer
```

## Overview

The system music player employs the Music app on your behalf.
When your app accesses the system music player for the first time,
it assumes the current Music app state and controls it as your app runs.
The shared state includes the following:

- Repeat mode (see [`MusicPlayer.RepeatMode`](/documentation/MusicKit/MusicPlayer/RepeatMode))
- Shuffle mode (see [`MusicPlayer.ShuffleMode`](/documentation/MusicKit/MusicPlayer/ShuffleMode))
- Playback status (see `MusicPlayer/PlaybackStatus`)

The system music player doesn’t share other aspects of the Music app’s
state. Music that’s playing continues to play when your app moves
to the background.

## Topics

### Instance Properties

[`var queue: MusicPlayer.Queue`](/documentation/MusicKit/SystemMusicPlayer/queue)

The playback queue for the system music player.

### Type Properties

[`static let shared: SystemMusicPlayer`](/documentation/MusicKit/SystemMusicPlayer/shared)

The shared system music player, which controls the Music app’s state.

## Relationships

### Inherits From

[`MusicPlayer`](/documentation/MusicKit/MusicPlayer)

---

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)