One of the most frustrating parts of having a small SSD dedicated to the Windows operating system is that some software installers will not give you the option to install it outside of the main drive.
There are even applications that allow you to store installation data on the secondary drive, but still put temporary or cache files on the primary drive. This can be a major problem for anyone interested in keeping the main unit tidy.
Spotify is one of many Windows applications that you will eventually find take up a lot of space. This is due to the way Spotify caches your data locally, so it does not continuously forward music from the server. It is a way for Spotify to save bandwidth and deliver music immediately without buffering.
However, for those of us trying to save precious disk space, this comes at a price. Not everyone can afford to have a few gigabytes of local Spotify data on their main drive, and the good news is that there is a way to solve this problem. Let’s talk about how to move Spotify’s local cache data to a new location in Windows.
Related: How to Use Google Docs Like a Pro?
How to Change the Location of Spotify Data in Windows
To accomplish this task, we will use something called symbolic link or directory link. The directory connection effectively mirrors your data in one file path, but actually stores the data in another file path.
The first thing we need to do is to find the exact location of the Spotify data folder. To do this, press the Windows + R keys to display the “Run” message. Here, type in “%localappdata” and press Enter.
This should open a Windows Explorer window for the AppData\Local folder in the location of your Windows user profile. In this list of files, find the Spotify folder and open it.
The data folder contains all cached music data. You may need to right-click and select “Properties” to see the size of this folder. Is it too large that you want to move it from the current unit to another unit? That’s great! This is what we will do next.
The first step is to make sure that Spotify is not currently running on your machine. After making sure it is closed, you need to select the Data folder and press Ctrl + C to copy.
Next, open the second Windows Explorer window where you want to move the Spotify data. In that location, press Ctrl + V to paste the folder.
Above, you can see that I’ve created a new location to store my data at D:\craig\Spotify. The pasted Data folder here contains the contents of that same folder in C:\Users\craig\AppData\Local\Spotify.
Next, make sure that the two folders are the same. Check both to see that you have successfully copied all files completely. When finished, go back to the original Spotify folder location (in the first Windows Explorer window of AppData\Local), select the Data folder we just copied, and press the Delete key to delete it.
Next, we will create a directory link so that your new data folder points to the location of the old folder. To do this, press the Windows + R keys to display the run prompt again. Type “cmd”, but be sure to press Ctrl + Shift + Enter (not just Enter); this runs the message as an administrator.
This is where we’ll begin to create our directory junction. You want to type in the following command: mklink /j <link> <target>, where <link> is the path to the original folder (that we’re recreating) and <target> is the path to the new folder (that we’ve pasted).
In my example above, I’d run this command: mklink /j C:\Users\craig\AppData\Local\Spotify D:\craig\Spotify
It’s important to enclose the folder paths in quotation marks if they contain a space.
After the directory connection is created, you will see a success message. You should also see that the Data folder now reappears in our original location, this time with the small “shortcut” icon in the lower left corner.
That is all! Now when you play music on Spotify, it will still cache the data in the original folder where it was linked. However, the directory node will automatically move it to the new location and “mirror” it to the original location.
For those who use Spotify every day, years of regular use will cause this folder to expand to a huge size. With this simple directory connection technique, you can store all your data in any folder on any drive.