Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Restoring a music playlist from a Time Machine backup.

Is there a way to retrieve one playlist that I deleted by mistake from a Time Machine backup and restore it to my Music App or iTunes library on my iMac? I can't seem to figure out how to find a specific playlist in Time Machine. I am not an Apple Music subscriber if that makes any difference. I have many playlists, and they are made up of music that I both bought from Apple and uploaded myself. When Apple made the iTunes changes, I just kept using the new Music App and adding purchased music to my library. I regularly back up my iMac to two external drives with Time Machine. Please tell me that Time Machine not only backs up tunes but playlists as well. I sure hope so.


If this can be done, please tell me the steps involved or where I can find them. Thanks.

Posted on Jan 23, 2022 3:39 PM

Reply
Question marked as Best reply

Posted on Jan 23, 2022 5:57 PM

This is over my head unless you help me further. Are we talking about restoring one playlist or my whole iTunes library of 18,000 songs and 40 playlists each with about 200 songs? I am assuming from your answer that my playlists are backed up but that I just haven't figured out how to access them, right?


In step one, you say rename the package. Where do I find the package? I assume this is done before I open up Time Machine in step two, right?

Similar questions

27 replies
Question marked as Best reply

Jan 23, 2022 5:57 PM in response to turingtest2

This is over my head unless you help me further. Are we talking about restoring one playlist or my whole iTunes library of 18,000 songs and 40 playlists each with about 200 songs? I am assuming from your answer that my playlists are backed up but that I just haven't figured out how to access them, right?


In step one, you say rename the package. Where do I find the package? I assume this is done before I open up Time Machine in step two, right?

Jan 23, 2022 3:58 PM in response to JazzmanJohn

  1. With Music closed rename the package ~/Music/Music/Music Library.musiclibrary as Music Library (Temp).musiclibrary.
  2. Restore the package ~/Music/Music/Music Library.musiclibrary from Time Machine from a date before you deleted the list.
  3. Open Music. Select the list and use File > Library > Export Playlist... Export as an XML file.
  4. Close Music. Rename Music Library.musiclibrary as Music Library (Old).musiclibrary.
  5. Rename Music Library (Temp).musiclibrary as Music Library.musiclibrary. Launch Music.
  6. Use File > Library > Import Playlist... and import the exported list.


tt2

Jan 24, 2022 10:52 AM in response to JazzmanJohn

Make sure Music is closed. Open Finder. Open your user's Music folder. Open the Music folder inside that. Now enter Time Machine by clicking the icon in the status area at the top of the screen. See Restore items backed up with Time Machine on Mac - Apple Support. Pick a suitable date, select the Music Library(.musiclibrary) file and click Restore. There is no point in overwriting all the unchanged media files. Deleting a playlist from the library doesn't delete any songs from it so those should have remained in place. The playlists are inside the file that you restore. Once this is done launch Music, the library should now be in the state it was in when it was backed up complete with the playlist that you removed in error.


tt2

Jan 23, 2022 6:49 PM in response to JazzmanJohn

~ is your user's profile folder. Your Music library is normally in the path mentioned in 1. above, i.e. the Music folder in the Music folder in your profile folder. The file Music Library.musiclibrary (which may appear without the extension) is actually a folder containing multiple files made to appear as a single file, i.e. it is a package. This contains the Music library database, which in turn contains all of your playlists. The aim of the steps above is to temporarily restore a recent version of this database, export the playlist as an XML file, restore your current database, then import the exported list.


A playlist is an ordered list of references to tracks in your library. Because they don't normally exist anywhere as individual files you need to temporarily restore an older version of your library database to recover the missing list.


tt2

Jan 24, 2022 4:18 AM in response to turingtest2

Since the terminology here is quite foreign, let's try to make this easier for me. Is there a way I can restore my entire iTunes library to the date of my last backup from Time Machine? If that restores my entire music database along with the music playlists, it seems to me that would be an easier fix. The key for me is that it must completely restore BOTH the music database AND the playlists. If this can be done without a lot of trouble, please tell me how to do it. That would solve my problem.

Jan 24, 2022 11:27 AM in response to turingtest2

I closed Music and opened Finder. Then I opened the Music folder on the left under Favorites and the Music folder inside that. That last Music folder contained a Music Library that was only 24.5 megabytes. Could that be right? I have 93 Gb of music in my library. I think I did this the other day, but I did not open the Music folder before trying to restore it from Time Machine. Maybe that's where I went wrong. We'll see. Please clarify before I do this. Thanks.

Jan 24, 2022 12:09 PM in response to turingtest2

There is a Media folder, but it only contains ringtones. There's an iTunes folder, an iTunes(original) folder and a Previous iTunes Libraries folder. I'm apprehensive about this. I wish I could speak with someone by phone for an assist. I've been diligently backing up my iMac for years, and you would think there would be an easy way top do it. I'm just a user but not a technical support person.

Jan 24, 2022 2:01 PM in response to JazzmanJohn

The User's Music folder is /Users/jazzman/Music/

Your Music library folder is /Users/jazzman/Music/Music

Your active Music library database is /Users/jazzman/Music/Music Library(.musiclibrary)


You can check to see if the last modified date of this last thing changes when you open and close Music. If so then this is the file that needs to be replaced with an earlier version from Time Machine. If not then perhaps you've created another .musiclibrary database somewhere along the way. You would need to find that file, and restore an older version of that file instead.


tt2

Jan 25, 2022 2:04 PM in response to JazzmanJohn

Here's what happened. I tried it several times. It appears to have replaced the Music Library but not the Either I made an error, or Time Machine does not back up Playlists. First I closed Music. Then I opened Finder>iMac>Users>Jazzman>Music>Music. The Music Library was there. I left that open and minimized it. Then I opened Time Machine and went back to Friday the 21st around 4:30 pm and selected the Music Library that appeared there(it did not appear as .musiclibrary). I hit restore. The following message appeared: An item named "Music Library" with extension ".musiclibrary" already exists in this location. Do you want to replace it with the one you're restoring? I said "Yes". I also went back to a January 6th backup and tried that one. It didn't work either. Like I say, either I missed a step or two or Time Machine does not back up Playlists. What's your take on this?

Restoring a music playlist from a Time Machine backup.

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.