Not a question but an additional solution: Migrate iTunes to Apple Music (includes star ratings, Last Played dates and Play Counts)
After following steps in other threads (scroll to bottom for reference) and adding steps of my own, I successfully migrated my entire music library along with star ratings, Last Played dates and Play Counts. Replace text shown both in italics, inside square brackets [] with your external drive name/ your user name/ your Mac hard drive name where appropriate. I hope you find these steps helpful.
- In Finder: I copied iTunes directories to [external drive] and rearranged to resemble Apple Music directory structure, making sure iTunes read all metadata correctly from copied library.
- In Finder: I copied the inner Music folder from [external drive] to Mac, under main Music folder, renaming it Music 1 to avoid conflict in preparation of Music app creating a new Music directory.
- Before opt-clicking Music app to select library (itl file in step 4), I modified then saved the iTunes Library.xml file (not the iTunes Music Library.xml) using a text editor/TextEdit
- Replacing all instances of Volumes/[external drive]/Music/Music/iTunes%20Media/Music/ with
- Users/[user name]/Music/Music 1/iTunes%20Media/Music/ (the location of the copied music files)
- I opt-clicked Music app and selected /Users/[user name]/Music/Music 1/iTunes Library.itl
- In Music app, Preferences/ Files/ Music Media folder location, I updated to: /[Mac hard drive name]/Users/[user name]/Music/Music 1/iTunes Media
- In Music app, to import the metadata (star ratings, plays, last played, etc) I selected File/ Library> (not Import…) Import Playlist… and selected xml file modified in step 3. Quit Music app.
- Opt-click Music app and select Music Library.musiclibrary
- In Music app, Preferences/ Files/ Music Media folder location, click Reset button then Ok to: /[Mac hard drive name]/Users/[user name]/Music/Music/Media
- Music will ask if you want to copy and rename files, answer YES. At this point, clicking … next to a song file in Music, Show in Finder will still point to the file under the iTunes folder.
- In Music app, select File/ Library/ Organize Library…, ✅ Consolidate flles, Music will update library as it copies song files from Music 1 folder under iTunes Media folder to Music under [Music app] Media folder.
- My result was 6% of album art did not transfer, I’m assuming due to image sizing or image type. 0.6% (not 6% as album art) of artists did not transfer; I then just copied/pasted missing artwork from iTunes on my old Mac, to my new Mac via AirDrop.
I started with the below thread, finding additional steps were necessary for a complete migration (extra steps included in my post above):
Move your iTunes library to a new computer - Apple Community
I would have posted this as a reply to this thread, but it is now inactive:
Old iTunes folder to Catalina or Big Sur … - Apple Community