Creating Symlinks to Solve the Unity Asset Store Download Problem

Note: This solution is for Windows users only - Sorry Mac uses. Linux users you should already know what you’re doing!

With the recent release of the Unity Humble Bundle, a lot of uses have found themselves left with a very full hard drive, whist others have been completely unable to download some of the chunkier audio assets due to a lack of C: Drive space.

Before we can fix the problem however, we need to know…

What’s going on.

In a nutshell, Unity uses a hidden file on your C: Drive to save the assets that you download from the store. Once downloaded, you can then import them into any project you like without having to re-download it every time. This reduces the traffic on their servers and also makes things a lot quicker for you - especially if your internet connection is a bit on the slow side.

Now, is this the best solution? Probably not. It would be nice if you could specify your own save location for these downloads. But, it’s been years since this problem was brought to their attention so it looks like we’re still stuck with it for now.

What’s the solution?

The solution dear reader is symlinks, or Symbolic Links. This approach will allow you to point to a folder and that link will then appear to be the same to Windows. Think of them like advanced shortcuts.

There are a few different types of Symlink available to you, including hard links and soft links, but to solve our Unity problem you’re going to want to use a directory junction.

How do I do that?

This is where things get fun! Follow the steps below and you should be set up in no time.

1. Locate the folder

This is located at: ”C:\Users\[YourUsername]\AppData\Roaming\Unity\Asset Store-5.x”

If you can’t see your AppData folder, then go to “View > Hidden Items” to reveal it. It will look slightly fainter than the other folders in the list.

2. Rename the folder

This is just a precautionary measure, in case you want to revert back during the process. You can rename it to whatever you want but I’d just prefix it with an underscore for simplicity.

3. Create a new folder

Create a new folder at your desired location. This can be anywhere you like and called anything you want. I went with the folder structure “Unity Assets\Cache“ on my E: drive.

4. Open Command Prompt

Go to “Start > Cmd“ and right-click to run as administrator.
Once this is open you should be in “C:\WINDOWS\system32“. If not, it’s not a big deal, just make sure you’re somewhere on the C: drive. You can do this by typing “cd c:\”

5. Create the Junction

To create the directory junction you need to use the mklink command, which follows the pattern:

mklink /J “AppData Folder“ “Your New Save Location“

So in my example, I would use:

mklink /J “C:\Users\[YourUsername]\AppData\Roaming\Unity\Asset Store-5.x“ “E\Unity Assets\Cache“

If you’re successful then you will see a message that the junction has been created. If it fails then follow the advice in the error message. A common one is that the file cannot be created if it already exists. This means that there’s a folder in AppData with the same name that you’re trying to use. This is why we renamed the original in step 2.

Note that the AppData folder must be named exactly as it was originally, that is “Asset Store-5.x“. If you name it anything different then Unity will not recognise the folder.

Once this is all done you will notice the new folder in AppData will have a small return arrow on the folder icon, signifying that it is now a type of shortcut. If you open it then it will appear as if contents are within that folder by they are actually stored in the other folder you created.

6. Testing

Now that the link is created, test it by opening up the asset store from within Unity. The program will quickly complain if something isn’t right but you may also want to try downloading a small asset to make sure that everything is connected up properly.

You will see that the asset is downloaded to your new save location. It will also be visible in the folder within AppData but will not be taking up space on your C: drive.

7. Clean Up

Now everything is working you want to clean up the last few things.

First, you may want to copy over any assets from the original AppData folder to your new save location. This may throw up a couple of problems within Unity, but you should be fine. If not, just re-download them from the asset store.

Finally, delete the original AppData folder that you renamed. This is no longer needed so you may as well get rid of it.

8. Celebrate!

Congratulations, if everything has gone according to plan you should have everything set up and working. Sit back, relax, and feel like a boss!

Disclaimer: I bear no responsibility for any damages or loss of work caused whilst following these instructions. These instructions are presented “as is”, with every effort being made to ensure that the information contained is accurate and safe. Users should make appropriate backups before beginning the process and use this guide at their own risk.

Gary Pettie6 Comments