# Installing and running Stable Diffusion UI

For more information about Stable Diffusion UI, see [this](https://github.com/AUTOMATIC1111/stable-diffusion-webui).

## Step 1: Deploy your Cloud GPU

You can deploy a GPU on our [Marketplace](https://marketplace.tensordock.com/order_list) to your specific configurations based on cost, RAM, storage, and vCPUs. Select Windows 10 as your installation.

Stable Diffusion UI works with both NVIDIA and AMD GPUs, but NVIDIA is preferred

<figure><img src="https://276866638-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FScYFYZoiZXazILi6lxJ5%2Fuploads%2FsYQvxmCITfzwDLXdT3fB%2Fimage.png?alt=media&#x26;token=2f28977b-d03d-4de1-b571-6984aeb4b30e" alt=""><figcaption><p>Ensure that you have selected Windows 10 as your installation</p></figcaption></figure>

## Step 2: RDP into your instance

Follow [this tutorial](https://docs.tensordock.com/marketplace/how-to-rdp-into-your-instance) to RDP into your Cloud GPU.

## Step 3: Install and run Stable Diffusion UI

**On your Remote Desktop**, perform the following:

1. Install [Python 3.10.6](https://www.python.org/ftp/python/3.10.6/python-3.10.6-amd64.exe) (Newer versions of Python do not support torch), and make sure to check "Add Python to PATH".
2. Install [git](https://github.com/git-for-windows/git/releases/download/v2.39.2.windows.1/Git-2.39.2-64-bit.exe).
3. Open Command Prompt from search bar, and type&#x20;

   `git clone https://github.com/AUTOMATIC1111/stable-diffusion-webui`
4. Double click the `run.bat` in your File Explorer to launch web UI, during the first launch it will download large amounts of files. After everything has been downloaded and installed correctly, you should see a message "`Running on local URL: http://127.0.0.1:7860`", opening the link will present you with the web UI interface.

<figure><img src="https://276866638-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FScYFYZoiZXazILi6lxJ5%2Fuploads%2Fhkg7EBYa9v02imgbzMzo%2Fimage.png?alt=media&#x26;token=6a2e542d-3b42-4c9c-98cf-8115cdba0704" alt=""><figcaption><p>Double click on the webui-user bat file in your file explorer. No need to run as administrator.</p></figcaption></figure>

<figure><img src="https://276866638-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FScYFYZoiZXazILi6lxJ5%2Fuploads%2FtJYf7fo4Bhnd2bbCTf95%2Fimage.png?alt=media&#x26;token=9fc9c547-e484-4bfa-903b-c3cc077c1e88" alt=""><figcaption><p>After all the installations are finished, look for the URL that the Web UI will be run on, in this case <code>http://127.0.0.1:7860</code></p></figcaption></figure>

<figure><img src="https://276866638-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FScYFYZoiZXazILi6lxJ5%2Fuploads%2FxV1kgjkX54iRKC0x25KE%2Fimage.png?alt=media&#x26;token=fa66a325-a5bc-4ca6-8f2b-8c476ba2714d" alt=""><figcaption><p>You can now open the URL in your web browser and use Stable Diffusion UI</p></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.tensordock.com/virtual-machines/installing-and-running-stable-diffusion-ui.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
