Is there a keyboard shortcut for "Save to Your Library" in Spotify's desktop app?

Save to Your Library is a great way to save favorite songs and play them back as a playlist later. It's also cool to make Your Library > Songs available offline on mobile. Then you're never without something good to listen to.

While listening on my desktop computer I'd like to effortlessly add the current track to my library.
Is there a keyboard shortcut to make this happen?

For reference, there was a similar feature called "Starred" with an outdated SuperUser Question here.


No keyboard shortcuts, let alone Save to Your Library, are built into Spotify desktop apps and probably never will. In December 2016 they marked the request (originally from 2012) as "Not Right Now".

For macOS users I don't know a solution.

For Windows users AutoHotkey is a fairly workable.

Here is an AutoHotkey script that works as of 10-30-2017.

; Control+Shift+Win+F1
^+#F1:: SendInput {Media_Play_Pause}

; Control+Shift+Win+F2
^+#F2:: SendInput {Media_Prev}

; Control+Shift+Win+F3
^+#F3:: SendInput {Media_Next}
    
; Control+Shift+Win+F4
^+#F4:: SaveSongToSpotifyLibrary()


SaveSongToSpotifyLibrary() {
    spotify := "ahk_exe spotify.exe"
    if WinExist(spotify) {
        ; Store starting window ID and mouse position.
        MouseGetPos x, y, startingWinId

        ; Activate Spotify.
        WinActivate %spotify%
        WinWaitActive %spotify%

        saveToYourLibraryIcon = %A_WorkingDir%\apps\SpotifyController\SaveToYourLibraryIcon.png
        ImageSearch FoundX, FoundY, 0, 0, A_ScreenWidth, A_ScreenHeight, %saveToYourLibraryIcon%
        if (ErrorLevel = 0) {
            Click %FoundX%, %FoundY%

        } else if (ErrorLevel = 2) {
            MsgBox % "Problem conducting image search. Is the saveToYourLibraryIcon in the correct location?"

        } else if (ErrorLevel = 1) {
            MsgBox % "Unable to save song. Can't find the Add button."
        }

        ; Restore original window and mouse position.
        WinActivate ahk_id %startingWinId%
        MouseMove %x%, %y%
    }
}

Instructions

  • If you've never created a script before please see the Beginner's Tutorial.

  • This uses the ImageSearch function. I created the image-to-find by taking a screenshot of the plus button in the bottom left corner of the Spotify app.
    You can create one yourself or download this one.
    SaveToYourLibrary Icon

  • Name it SaveToYourLibraryIcon.png and place it in the same directory as your script.

  • That's it. Press Ctrl+Shift+Win+F4 (change this to whatever you want) and the active song will be added to your library!


Alt + Shift + B works on Windows when Spotify is the active window.

You can check out all keyboard shortcuts by pressing Ctrl + /