# Installation for Unity

You can download and install **Yarn Spinner for Unity** in a variety different ways.

{% hint style="danger" %}
Yarn Spinner for Unity 3 is compatible with **Unity version 2022.3 and newer.** If you need to use an older version of Unity, use Yarn Spinner 2.x, which supports Unity 2021.3.
{% endhint %}

**Yarn Spinner** is developed in the open, and the best ways to download and install Yarn Spinner for Unity, and the ones that support us to continue developing it the most are via the [Yarn Spinner Itch.io Store](https://yarnspinner.itch.io/) and the [Unity Asset Store](https://assetstore.unity.com/packages/tools/behavior-ai/yarn-spinner-for-unity-267061).

{% tabs %}
{% tab title="Unity Asset Store" %}
**Install from the Unity Asset Store**

First, [visit the Unity Asset Store page for Yarn Spinner for Unity](https://assetstore.unity.com/packages/tools/behavior-ai/yarn-spinner-for-unity-267061), and add it to your cart, and complete your purchase while logged into the same Unity account you use to activate Unity.

<figure><img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-8110d53563d73879f1a319cfb5d4b92a4a28d367%2FScreenshot%202024-01-31%20at%203.48.43%E2%80%AFpm.png?alt=media" alt=""><figcaption></figcaption></figure>

Once you've purchased Yarn Spinner for Unity, you'll find the Add to Cart button replaced by an Open in Unity button. Click this button to launch Unity, and the Package Manager will locate your purchased package:

<figure><img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-d0817554d8cddd7c779710fbf86bfc904af85e03%2FScreenshot%202024-01-31%20at%203.41.36%E2%80%AFpm.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>

Once the Package Manager has located the package, you can use the Download button to fetch it:

<figure><img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-dea932ab827a41105a7d7e0369c811a96038d02b%2FScreenshot%202024-01-31%20at%203.42.04%E2%80%AFpm.png?alt=media" alt=""><figcaption></figcaption></figure>

Once Yarn Spinner for Unity has downloaded, you can use the Import button to start the process of adding it to your project:

<figure><img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-b42f035fb984de2c8d534adfeada566ad0d43b87%2FScreenshot%202024-01-31%20at%203.43.55%E2%80%AFpm.png?alt=media" alt=""><figcaption></figcaption></figure>

This will trigger the Import Unity Package workflow, where you can use the Import button to add the Yarn Spinner for Unity package to your project:

<figure><img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-ac0864164aa348edaea45cbf4db043f74a9b485b%2FScreenshot%202024-01-31%20at%203.46.55%E2%80%AFpm.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>

And with that, you're ready to use Yarn Spinner! You might also want to download and import the Yarn Spinner for Unity Samples as a `.unitypackage`, from here.

{% hint style="info" %}
You can review [Unity's documentation for using the Asset Store](https://docs.unity3d.com/Manual/AssetStorePackages.html) for further guidance on working with purchased packages.
{% endhint %}
{% endtab %}

{% tab title="Itch.io" %}
**Install from Itch.io**

First, visit the [Yarn Spinner Itch.io Store](https://yarnspinnertool.itch.io/yarn-spinner), and click the Buy Now button, and complete the checkout process.

Once you've purchased Yarn Spinner, you'll find a Download button at the top of the page:

<figure><img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-f03305fa59513bf9d684710048429c962562ada1%2FPNG%20image.jpeg?alt=media" alt=""><figcaption></figcaption></figure>

The download button will take you the following page, where you can download the Yarn Spinner for Unity `.unitypackage`:

<figure><img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-24b985f78dfb6cdf85f248569825ebac0a6ea0b2%2FPNG%20image%20(1).jpeg?alt=media" alt=""><figcaption></figcaption></figure>

Once you've downloaded the `.unitypackage`, with the Unity project you want to use it in open and ready to go, double click it. Unity will then allow you to import the package into your project:

<figure><img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-305f489d3780c6961990ade9d4344970a29d513c%2FScreenshot%202023-11-29%20at%204.03.41%E2%80%AFpm.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>
{% endtab %}

{% tab title="Manually" %}
**Install from GitHub**

As an alternative to downloading Yarn Spinner from OpenUPM, you can install Yarn Spinner by downloading the package directly from GitHub, where the project's source code is stored.

{% hint style="info" %}
Where possible, we recommend installing Yarn Spinner via a purchased `.unitypackage` from the [Yarn Spinner Itch.io](https://yarnspinner.itch.io/) or the [Unity Asset Store](https://assetstore.unity.com/packages/tools/behavior-ai/yarn-spinner-for-unity-267061).
{% endhint %}

To install Yarn Spinner from GitHub, follow these instructions.

1. Make sure your system [has Git (minimum version 2.14.0) installed](https://git-scm.com/).
2. In Unity, open the Window menu, and choose Package Manager.
3. Click the `+` button, and choose "Add package from git URL".
4. In the text field that appears, enter the following URL:\
   \&#xNAN;**`https://github.com/YarnSpinnerTool/YarnSpinner-Unity.git#current`**\
   Be sure to type the URL exactly as it appears in this document.
5. The project will download and install. This might take a moment.

**Install via OpenUPM**

You can also install the Yarn Spinner package into your project using the Package Manager window in Unity. Specifically, Yarn Spinner is available via the [OpenUPM registry](https://openupm.com).

In order to follow the instructions in this section, your project needs to be using Unity 2020.1 or higher. If your project is using an earlier version of Unity, we recommend installing Yarn Spinner from Git.

{% hint style="info" %}
Where possible, we recommend installing Yarn Spinner via a purchased `.unitypackage` from Itch.io or the Unity Asset Store.
{% endhint %}

**Setting Up the OpenUPM Registry in Your Project**

Before you can install Yarn Spinner from OpenUPM, you first need to configure your project so that it knows where to get the package from.

1. In Unity, open the Edit menu, and choose Project Settings.
2. In the list of sections at the left hand side of the window, select Package Manager.

This window is where you tell Unity about where to find packages that come from registries besides Unity's built-in one.

1. In the Name field, type `OpenUPM`.
2. In the URL field, type `https://package.openupm.com`.
3. In the Scopes field, type `dev.yarnspinner`.
4. Click Save.

When you're done, the settings window should look like this:

<img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-9ffc8d7043c45fa1fa36c6865b735bc8180c3666%2Finstalling-unity-package-manager-registry.png?alt=media" alt="" data-size="original">

You can now install Yarn Spinner itself.

**Installing the Yarn Spinner package**

1. Open the Window menu, and choose Package Manager.
2. In the toolbar, click Packages: In Project, and choose My Registries.

<img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-4b36cb70469b92bbc1976649e0a4efca76a4d829%2Finstalling-unity-package-manager-select-package-list.png?alt=media" alt="" data-size="original">

1. Yarn Spinner will appear in the list. Select it, and click Install.

<img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-39d975f5cf3b8bd1432becad8215db25d46cb9a5%2Finstalling-unity-package-manager-registry-select-package.png?alt=media" alt="" data-size="original">

Yarn Spinner will download and install into your project.

You can verify that everything is imported succesfully by looking for Yarn Spinner under Packages, in the Project pane.

<img src="https://463139507-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FGAKWviXNATe9kDFWZAco%2Fuploads%2Fgit-blob-c2f12a9b2c98158463950633699e0a6b4ac14589%2FScreen%20Shot%202021-03-07%20at%202.16.14%20pm%20(1).png?alt=media" alt="Verify that Unity has the package by checking the Packages folder of the Project pane." data-size="original">
{% endtab %}
{% endtabs %}

### What's the difference between the versions?

<table><thead><tr><th width="270.49609375"></th><th align="center">Itch.io</th><th align="center">Asset Store</th><th align="center">Manual</th></tr></thead><tbody><tr><td>Full Unity Integration</td><td align="center">✅ Included</td><td align="center">✅ Included</td><td align="center">✅ Included</td></tr><tr><td><a href="unity-add-ons/text-animator">Text Animator for Yarn Spinner</a></td><td align="center">✅ Included</td><td align="center">✅ Included</td><td align="center"></td></tr><tr><td>Unity Localization</td><td align="center">✅ Included</td><td align="center">✅ Included</td><td align="center">✅ Included</td></tr><tr><td>Voice-over</td><td align="center">✅ Included</td><td align="center">✅ Included</td><td align="center">✅ Included</td></tr><tr><td>Community Support</td><td align="center">✅ Included</td><td align="center">✅ Included</td><td align="center">✅ Included</td></tr><tr><td>Direct Support</td><td align="center">✅ Included</td><td align="center">✅ Included</td><td align="center"></td></tr></tbody></table>

{% hint style="info" %}
Yarn Spinner is an open source project. You can directly support the Yarn Spinner Team by purchasing Yarn Spinner from [Itch](https://yarnspinner.itch.io) or the [Unity Asset Store](https://assetstore.unity.com/packages/tools/behavior-ai/yarn-spinner-for-unity-267061), but it will always have a free option as well. To support the continued development of Yarn Spinner, purchase Yarn Spinner for Unity from one of the storefronts. This is the best way to directly support the Yarn Spinner team.
{% endhint %}
