---
title: How to Deploy the FLUX.1-schnell Image Generation Model on Vultr Cloud GPU
url: https://docs.vultr.com/how-to-deploy-the-flux-1-schnell-image-generation-model-on-vultr-cloud-gpu
description: Learn how to deploy the FLUX.1-schnell image generation model on Vultr Cloud GPU with our step-by-step guide for fast, efficient AI image creation.
publish_date: 2025-01-17T13:23:28.236073Z
last_updated: 2026-04-15T00:00:00.077250Z
author: Martin Sustak
header_image: https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/1c1787c7-b7ed-4599-990f-f6c442729279.png
---

> Index of every Vultr Docs page in markdown: https://docs.vultr.com/llms.txt

## Introduction

Deploy Flux 1-schnell to harness the power of open-source generative AI for creating images from text prompts. This streamlined version of the original Flux-pro model offers faster performance while retaining text embedding capabilities for enhanced image generation. Built on a transformer architecture with 12 billion parameters, Flux 1-schnell supports LoRA (Low-Rank Adaptations) to produce highly realistic images efficiently.

This article explains how to deploy the FLUX.1-schnell image generation model on a Vultr Cloud GPU server. You will use the ComfyUI web interface to create an image generation workflow and set up LoRAs to enhance the quality of the generated images.

## Prerequisites

Before you begin:

* Deploy an [NVIDIA A100 Vultr Cloud GPU instance running Ubuntu](https://console.vultr.com/deploy/) and enable the [**Limited User Login** feature](https://docs.vultr.com/limited-user-login).
* Access the instance [using SSH](https://docs.vultr.com/how-to-use-ssh-with-vultr-servers/).
* [Install ComfyUI on the instance](https://docs.vultr.com/how-to-deploy-comfyui-on-vultr-cloud-gpu).
* [Sign up or Log in](https://huggingface.co/login) to your Hugging Face account.

## Download the Flux-schnell Model

The `huggingface_hub` Python library includes a special function for downloading the Flux-schnell model. Follow the steps below to install the `huggingface_hub` library and create a new Python script to download the Flux-schnell model.

1. Switch to your user's home directory.

    ```console
    $ cd /home/linuxuser/
    ```

1. Create a new directory, such as `flux` to store the model files.

    ```console
    $ mkdir flux
    ```

1. Switch to the new `flux` directory.

    ```console
    $ cd flux
    ```

1. Use Pip to install the `huggingface_hub` Python library.

    ```console
    $ pip install huggingface_hub
    ```

1. Create a new `schnell_model_downloader.py` file.

    ```console
    $ nano schnell_model_downloader.py
    ```

1. Add the following Python script to the `schnell_model_downloader.py` file. Replace `/home/linuxuser/flux` with your actual model directory.

    ```python
    from huggingface_hub import snapshot_download
    snapshot_download(repo_id="black-forest-labs/FLUX.1-schnell", local_dir="/home/linuxuser/flux")
    ```

    Save and close the file.

    The above Python script imports the `huggingface_hub` library for downloading the Flux-schnell model files. The `snapshot_download` function downloads the model from the `black-forest-labs/FLUX.1-schnell` Huggingface repository to the `/home/linuxuser/flux` directory.

1. Run the script using Python to download the Flux-schnell model files and wait at least 10 minutes for the model to download.

    ```console
    $ python3 schnell_model_downloader.py
    ```

    Output:

    ```
    ...
    model-00002-of-00002.safetensors: 100%|███████████████████████████████████████████████████████████████| 4.53G/4.53G [01:50<00:00, 40.9MB/s]
    (...)model-00001-of-00002.safetensors: 100%|███████████████████████████████████████████████████████████████| 4.99G/4.99G [02:00<00:00, 41.4MB/s]
    (...)pytorch_model-00002-of-00003.safetensors: 100%|████████████████████████████████████████████████████| 9.95G/9.95G [03:59<00:00, 41.6MB/s]
    pytorch_model-00001-of-00003.safetensors: 100%|████████████████████████████████████████████████████| 9.96G/9.96G [04:02<00:00, 41.1MB/s]
    flux1-schnell.safetensors: 100%|██████████████████████████████████████████████████████████████████████| 23.8G/23.8G [09:30<00:00, 41.7MB/s]
    Fetching 28 files: 100%|███████████████████████████████████████████████████████████████████████████████████| 28/28 [09:31<00:00, 20.40s/it]
    ```

1. Move the `flux1-schnell.safetensors` file to the `models/unet` directory in your ComfyUI project.

    ```console
    $ sudo mv flux1-schnell.safetensors /opt/ComfyUI/models/unet/
    ```

1. Move the `ae.safetensors` file to the `models/vae` directory in your ComfyUI project.

    ```console
    $ sudo mv ae.safetensors /opt/ComfyUI/models/vae
    ```

    The above command moves the `ae.safetensors` variational encoder file required by the model to enhance the visual quality of generated images.

## Set up the Flux-schnell Model in ComfyUI

ComfyUI requires multiple files to run models on a server. Follow the steps below to download the required Flux-schnell model files to your ComfyUI project directory.

1. Switch to the `models/clip` directory in your ComfyUI project.

    ```console
    $ cd /opt/ComfyUI/models/clip
    ```

1. Download the Flux-schnell `clip_l.safetensors` file.

    ```console
    $ sudo wget https://huggingface.co/comfyanonymous/flux_text_encoders/resolve/main/clip_l.safetensors
    ```

    The above command downloads the clip model used by the Flux-schnell model during the image generation process to support text inputs.

1. Download the Flux-schnell `t5xxl_fp16.safetensors` file.

    ```console
    $ sudo wget https://huggingface.co/comfyanonymous/flux_text_encoders/resolve/main/t5xxl_fp16.safetensors
    ```

    The above command takes between 2 and 5 minutes to download the FP16 model file used by Flux-schnell to encode text inputs. The model uses the FP16 precision standard to balance the model's image generation quality and performance.

## Generate Images Using the Flux-schnell Model in ComfyUI

ComfyUI generates images using workflows in the form of interconnected nodes. Workflows connect multiple AI image generation components to produce a final image. ComfyUI loads workflows from sources such as configuration or image files. Follow the steps below to load the Flux-schnell image generation workflow and generate images using ComfyUI.

1. Access your ComfyUI domain using a web browser such as Chrome.

    ```
    https://comfyui.example.com
    ```

1. Download the following image to your workstation to load the Flux-schnell workflow in ComfyUI.

    ![Flux-schnell Workload Image](https://i.ibb.co/VMFxW4V/Comfy-UI-00002.png)

1. Click **Load** in the floating ComfyUI menu to browse and open the workflow image on your workstation.

    ![Load the Workload in ComfyUI](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/62848ec9-9d3d-4c73-9a2d-9dc1bacc349e.png)

1. Find the **Prompt** node and enter a new text prompt to generate images. For example, `A photorealistic image of a golden retriever dog with soulful brown eyes, lying on a soft rug in front of a cozy fireplace, with a warm glow illuminating its fur. The dog is relaxed, with its head resting on its paws, and its tail gently curled around its body. In the background, a peaceful living room with comfy furniture and soft lighting creates a calm, serene atmosphere.`.
1. Click **Queue Prompt** to generate the image using the Flux-schnell model.

    ![Generate the Image in ComfyUI](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/b309a6bd-ba2a-4da0-bf67-d44e12be3d2a.png)

1. Wait at least 30 seconds for the image generation process to complete and verify the image in the **Save Image** node.

    ![Preview Generated Image in ComfyUI](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/a1e708d9-b472-485f-816b-b0373863d35c.png)

## Download the Flux-dev Model

The Flux-schnell development (Flux-dev) model generates higher-quality images at a slower generation speed as compared to the main Flux-schnell model. LoRas also require the Flux-dev model in order to generate higher-quality images. Follow the steps below to generate a new Hugging Face access token and download the Flux-dev model on your server.

1. Visit the [Flux-dev model page](https://huggingface.co/black-forest-labs/FLUX.1-dev) on Hugging Face.
1. Click **Agree** to accept the model's terms and conditions.

    ![Agree to the Terms and Conditions for Using the Dev Model](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/30af2833-6076-468c-ab49-9ddaf02c682c.png)

1. Visit the [Tokens page](https://huggingface.co/settings/tokens) in your Hugging Face account settings.
1. Click **Create new token**.

    ![Create a new Huggingface Authorization Token](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/ed336cfb-9445-43e4-9fba-6bf2cf864d68.png)

1. Enter your desired token name and description in the respective fields.
1. Check the `Read access to contents of all public gated repos you can access` within the **User Permissions** section to access the Flux-dev repository using the token.

    ![Configure the Correct Token Permission](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/5a63d3f6-196c-49de-a9c1-59731a21513b.png)

1. Scroll and click **Create token** to apply the new token to your Hugging Face account.

    ![Create a new Huggingface Authorization Token](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/1441d078-ea4f-4975-b470-a66fc6f4cade.png)

1. Click **Copy** to save the token to your clipboard.

    ![Copy the Token To Your Clipboard](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/81a48b34-721f-42f4-97f7-0fd248c52e7e.png)

1. Switch to the `flux` directory you created earlier in your user's home directory. Replace `/home/linuxuser/flux` with your actual path.

    ```console
    $ cd /home/linuxuser/flux
    ```

1. Create a new `dev_model_downloader.py` file.

    ```console
    $ nano dev_model_downloader.py
    ```

1. Add the following Python script to the `dev_model_downloader.py` file. Replace `YOUR_ACCESS_TOKEN` with your Hugging Face token and `/home/linuxuser/flux` with your actual path.

    ```python
    from huggingface_hub import snapshot_download
    from huggingface_hub import login
    login(token="YOUR_ACCESS_TOKEN")
    snapshot_download(repo_id="black-forest-labs/FLUX.1-dev", local_dir="/home/linuxuser/flux")
    ```

    Save and close the file.

    The above Python script runs the `login(...)` function from the `huggingface_hub` library to download the Flux-dev model using the `snapshot_download(...)` function and your Hugging Face token.

1. Run the `dev_model_downloader.py` script using Python.

    ```console
    $ python3 dev_model_downloader.py
    ```

    Wait at least 10 minutes for the model to finish downloading and verify that your output is similar to the one below when successful.

    ```
    (…) pytorch_model-00003-of-00003.safetensors: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.87G/3.87G [01:35<00:00, 40.5MB/s]  
    (…) pytorch_model-00002-of-00003.safetensors: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 9.95G/9.95G [03:57<00:00, 41.9MB/s]  
    (…) pytorch_model-00001-of-00003.safetensors: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 9.98G/9.98G [03:58<00:00, 41.9MB/s]  
    flux1-dev.safetensors: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 23.8G/23.8G [09:29<00:00, 41.8MB/s]  
    Fetching 29 files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 29/29 [09:29<00:00, 19.65s/it]
    ```

1. Move the `flux-dev` model files to the `models/unet` directory in your ComfyUI project.

    ```console
    $ sudo mv flux1-dev.safetensors /opt/ComfyUI/models/unet/
    ```

1. Access the ComfyUI interface using your domain in a new web browser window.

    ```
    https://comfyui.example.com
    ```

1. Download the following image to your workstation to load a new Flux-dev workflow in ComfyUI.

    ![Flux-dev Workload Image](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/4aa6e6b8-7dac-4df6-9be2-b3aa0e258089.png)

    The Flux-dev workflow allows you to generate images with the Flux-dev model and contains all necessary paths required by the model.

1. Click **Load** in ComfyUI to browse the image from your workstation and load the Flux-dev workflow.

    ![Load the Workload in ComfyUI](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/62848ec9-9d3d-4c73-9a2d-9dc1bacc349e.png)

1. Enter a new text prompt in the **Prompt** node. For example, enter the prompt `A photorealistic image of a golden retriever dog with soulful brown eyes, lying on a soft rug in front of a cozy fireplace, with a warm glow illuminating its fur. The dog is relaxed, with its head resting on its paws, and its tail gently curled around its body. In the background, a peaceful living room with comfy furniture and soft lighting creates a calm, serene atmosphere.`.
1. Click **Queue Prompt** to generate the image using the Flux-dev model.

    ![Generate the Image in ComfyUI](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/a94fdf9d-5966-485f-aa09-e93477736237.png)

1. Wait at least 30 seconds for the image generation process to complete and verify the image in the **Save Image** node.

    ![Preview Generated Image in ComfyUI](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/ae1eacf0-426f-45ef-844c-1b97262dd1f0.png)

## Set up LoRAs to Generate More Realistic Images

LoRAs are additional model files that increase the realism of generated images including faces. Follow the steps below to set up LoRAs developed by XLabs AI to increase the quality of images generated by the Flux-dev model.

1. Switch to the `models/loras` directory in your ComfyUI project.

    ```console
    $ cd /opt/ComfyUI/models/loras
    ```

1. Download the LoRAs file for the Flux-dev model.

    ```console
    $ sudo wget https://huggingface.co/comfyanonymous/flux_RealismLora_converted_comfyui/resolve/main/flux_realism_lora.safetensors
    ```

1. Download the following image to your workstation to load the Flux-dev image generation workflow with LoRAs in ComfyUI.

    ![Flux with Loras Workload Image](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/9e2d32ea-5e30-4028-88fb-1317d5e812f1.png)

1. Click **Load** in ComfyUI to browse the image and open the LoRAs workflow.

    ![Load the Workload in ComfyUI](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/62848ec9-9d3d-4c73-9a2d-9dc1bacc349e.png)

1. Enter a new text prompt in the **Prompt** that contains a face to test the LoRAs output. For example, enter the prompt, `A photorealistic image of a young man's face with short, dark hair and smooth skin. He has a focused, thoughtful expression, with relaxed eyes and a slight, confident smile. Soft lighting from one side highlights his sharp cheekbones and well-defined jawline, bringing out the natural contours of his face. The background is simple and blurred, emphasizing his facial features and calm demeanor.`.
1. Click **Queue Prompt** to generate a new image using the model.

    ![Generate the Image in ComfyUI](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/261485f5-a51d-4efd-a712-11106223944b.png)

1. Wait at least 30 seconds for the image generation process to complete and view the image in the **Save Image** node.

    ![Preview Generated Image in ComfyUI](https://assets.vultrdevrel.com/docs-main-doc-assets-1/2030/3336231a-0a04-4fcb-a2d0-563d94afeb57.png)

## Troubleshooting

ComfyUI may display some errors while generating images using the Flux-schnell model. Use the following solutions to fix any errors on your server.

* `torch.cuda.OutOfMemoryError`: Upgrade your GPU server plan or clear the GPU memory to generate images using the Flux-schnell model.
* `Numpy is not available`: Verify the latest supported ComfyUI Numpy version and install it on your server. For example, Install the `numpy<2` package using Pip as required by most ComfyUI versions.

## Conclusion

You have deployed the Flux-schnell model on a Vultr Cloud GPU server and generated images using ComfyUI. In addition, you deployed the Flux-dev model to increase the generated image output quality and set up LoRAs to enable the model to produce more realistic images. For more information, workflow, and model options, please visit the official [Flux-schnell Hugging Face page](https://huggingface.co/black-forest-labs/FLUX.1-schnell).
