MusicKit


MusicKit lets users play Apple Music and their local music library natively from your apps and now websites. When a user provides permission to their Apple Music account, your app can create playlists, add songs to their library, and play any of the millions of songs in the Apple Music catalog. If your app detects that the user is not yet an Apple Music member, you can offer a trial from within your app.

New

Introducing MusicKit on the Web

Now songs from Apple Music can play directly in your browser. With the new Apple Music player, you can stream songs from Apple Music in your websites using the default player or one you’ve customized. Find out how to add an Apple Music player to your website using JavaScript.

Watch “MusicKit on the Web”

Learn more about MusicKit JS

Getting Started

Set up your MusicKit identifiers, keys, and tokens by signing in to your developer account and visiting Certificates, Identifiers & Profiles. To communicate with the Apple Music service, you’ll need to use your MusicKit private key to sign one or more developer tokens. A developer token is required in the header of every Apple Music API request.

Learn about the MusicKit identifier and private key

Integrating Apple Music into Your iOS App

Get details on how to build iOS apps that integrate Apple Music using the Apple Music API, and the StoreKit and MediaPlayer frameworks.

Authorize Apple Music with StoreKit

Check if a user has an Apple Music membership to automatically play the music, or let them start a trial membership directly within your app using StoreKit.

Learn about StoreKit

Request Music Data with the Apple Music API

Use the Apple Music API to let your app search for songs, playlists, artists, and more. Your app can also request music we think your users will love.

Learn about the Apple Music API

Control Playback with MediaPlayer

Play any song from Apple Music and access a user's music library, with their permission.

Learn about MediaPlayer

Introducing MusicKit

Discover the API for the Apple Music subscription service with this WWDC video.

Watch now