> For the complete documentation index, see [llms.txt](https://docs.defguard.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.defguard.net/2.1/using-defguard-for-end-users/desktop-client/instance-configuration.md).

# Instance configuration

{% hint style="warning" %}
Defguard Desktop Client is required if you want to use Multi-Factor Authentication, as any other WireGuard client doesn't support this functionality.
{% endhint %}

### Obtaining URL and Token

{% hint style="info" %}
If you are looking for how to generate tokens for your users as an Administrator, look here:

[Adding client device](/2.1/features/wireguard/remote-desktop-activation.md)
{% endhint %}

1. Log in to your Defguard account.
2. Go to **My Profile** tab and select **Devices** tab.

<figure><img src="/files/MIEjJKRw2nNvaoI1qwJ8" alt="" width="50%"><figcaption></figcaption></figure>

3. Click **Add new device** button.

<figure><img src="/files/cVDhJAPrGf83LMIvrPAn" alt="" width="50%"><figcaption></figcaption></figure>

4. Click **Client Activation**.

<figure><img src="/files/XWPMS6lNPc9rnabodahk" alt="" width="50%"><figcaption></figcaption></figure>

5. Afterwards, use **One-Click Configuration** or click **Show advanced configuration** and copy **URL** and **Token** manually.

<figure><img src="/files/r4mcrFI9rRJmoq9yOi90" alt="" width="375"><figcaption></figcaption></figure>

### Manually Adding Instance

1. If you don't have **Defguard** in full view mode, open **Defguard** from tray view, and click **Open Defguard**

<figure><img src="/files/KuKzUU2nSjYMN7bffWPV" alt="" width="50%"><figcaption></figcaption></figure>

2. Click **Add Instance**.

<figure><img src="/files/QrE7vqGWhwgHJCmsjgQY" alt=""><figcaption></figcaption></figure>

3. Enter URL, Token and Device name of your choice, then click **Add Instance**. (If you don't have URL/Token, check out [this section](#obtaining-url-and-token))

<figure><img src="/files/JEBkXsoE1OKtWGymZkih" alt=""><figcaption></figcaption></figure>

### One-click Desktop Configuration

You can skip the whole process of entering the token/URL by clicking "One-Click Desktop Configuration". Here is a video describing the whole process:

{% embed url="<https://www.youtube.com/embed/q5-AXOPLgHc>" %}

### Connecting to Instance

#### Desktop client in full view mode

1. Go to **Instances**

<figure><img src="/files/Vp0EzC3HTCDCrK1RBN7g" alt=""><figcaption></figcaption></figure>

2. Select the instance you want to use

<figure><img src="/files/qco7fImGhwJn9swV3Zyo" alt=""><figcaption></figcaption></figure>

3. Choose allowed traffic

{% hint style="info" %}

* **Predefined traffic only** will only route traffic specified by your administrator.
* **All traffic is allowed** will route everything through VPN tunnel.
  {% endhint %}

<figure><img src="/files/rI1Mx6rLQR7IeQZsysNU" alt=""><figcaption></figcaption></figure>

4. Click **Connect VPN**

<figure><img src="/files/wViLbWRt74SEwocXFvrY" alt=""><figcaption></figcaption></figure>

#### Desktop client in tray view mode

1. Click on instance list

<figure><img src="/files/xNKKAk3D8z5dCfAV02AG" alt=""><figcaption></figcaption></figure>

2. Select the instance you want to connect to

<figure><img src="/files/wyYwXRJs35nuPE3tKYWi" alt=""><figcaption></figcaption></figure>

3. Choose allowed traffic

{% hint style="info" %}

* **Predefined traffic only** will only route traffic specified by your administrator.
* **All traffic is allowed** will route everything through VPN tunnel.
  {% endhint %}

<figure><img src="/files/iSgBf1418f8bQg4H05Af" alt=""><figcaption></figcaption></figure>

4. Click **Connect VPN**

<figure><img src="/files/uhh8qWQPKsgKNDfk6u3k" alt=""><figcaption></figcaption></figure>

### Disconnecting from Instance

Click **Disconnect** next to the location you are currently connected to.

<figure><img src="/files/AEnslklZIAtIjpL7ZCPU" alt=""><figcaption></figcaption></figure>

### Updating Instance

If you want to update your instance manually:

1. If you don't have **Defguard** in full view mode, open **Defguard** from tray view, and click **Open Defguard**

<figure><img src="/files/KuKzUU2nSjYMN7bffWPV" alt="" width="50%"><figcaption></figcaption></figure>

2. Go to your Instance and click **Instance settings**

<figure><img src="/files/O0AchrlnO0t0unV7LJw6" alt=""><figcaption></figcaption></figure>

3. Click **Update**

<figure><img src="/files/uKrHV3bBjWWF6Xs8hBZd" alt=""><figcaption></figcaption></figure>

{% hint style="warning" %}
Only tokens issued from that specific instance will work.
{% endhint %}

4. Enter Token provided by your administrator, or generate it [on your own](#obtaining-url-and-token). Then click **Update**

<figure><img src="/files/jVwc3ETyB9DBInzN70ri" alt=""><figcaption></figcaption></figure>

Your Instance will update immediately.

### Why do instances need updates?

Defguard Desktop stores all information locally and doesn't communicate with Defguard outside the registration process. This means that the information about an instance is a snapshot of the moment you registered it in the desktop client, and you might want to update it, for example when locations are added or removed.

{% hint style="success" %}
If you have a Business or Enterprise plan, all desktop clients and all instances are [synchronized automatically and in real-time.](/2.1/features/remote-user-enrollment/automatic-real-time-desktop-client-configuration.md)
{% endhint %}

### Removing Instance

1. If you don't have **Defguard** in full view mode, open **Defguard** from tray view, and click **Open Defguard**

<figure><img src="/files/KuKzUU2nSjYMN7bffWPV" alt="" width="50%"><figcaption></figcaption></figure>

2. Go to your Instance, click **Instance settings**

<figure><img src="/files/O0AchrlnO0t0unV7LJw6" alt=""><figcaption></figcaption></figure>

3. Click **Delete**

<figure><img src="/files/of2NvTRFRRpiiMQeldFa" alt=""><figcaption></figcaption></figure>

4. Confirm with **Delete instance** button

<figure><img src="/files/zKGQigiX3RsBnTYLnyEC" alt=""><figcaption></figcaption></figure>

Your Instance will be removed immediately.
