Remove one or more tracks from the current user’s “Your Music” library.

Changes to a user’s saved tracks may not be visible in other Spotify applications immediately.



Request Parameters

Note that the Spotify IDs of the tracks to remove can be passed either as a JSON array in the request body or as a list in the query string.

Header field
AuthorizationRequired. A valid access token from the Spotify Accounts service: see the Web API Authorization Guide for details.

Modification of the current user's "Your Music" collection requires authorization of the user-library-modify scope.
Content-TypeRequired if the IDs are passed in the request body, otherwise ignored. The content type of the request body: application/json

Query argument
Optional. A comma-separated list of the Spotify IDs. For example: ids=4iV5W9uYEdYUVa79Axb7Rh,1301WleyT98MSxVHPZCA6M. Maximum: 50 IDs.

Request body data
Value typeValue
array of Spotify ID stringsOptional. A JSON array of the Spotify IDs. For example:
["4iV5W9uYEdYUVa79Axb7Rh", "1301WleyT98MSxVHPZCA6M"]

A maximum of 50 items can be specified in one request. Note: if the ids parameter is present in the query string, any IDs listed here in the body will be ignored.

Response Format

On success, the HTTP status code in the response header is 200 Success. On error, the header status code is an error code and the response body contains an error object. Trying to remove a track when you do not have the user’s authorization returns error 403 Forbidden.

Example (remove the request body’s tracks from “Your Music”)

Note that cURL requires quotation marks within the JSON data to be escaped, for example. \"4iV5W9uYEdYUVa79Axb7Rh\".
curl -i -X DELETE "" -H "Authorization: Bearer {your access token}" -H "Content-Type: application/json" --data "[\"4iV5W9uYEdYUVa79Axb7Rh\", \"1301WleyT98MSxVHPZCA6M\"]"
HTTP/1.1 200 Success

Try it