Skip to content

Download CivitAI models at boot

Configure a supported template to fetch LoRAs and checkpoints directly into the pod.

All guides

The MiniMax H3, LTX, Qwen / Krea / Z Image and Wan templates can download CivitAI LoRAs and checkpoints when the pod starts. Add your API token and model-version IDs before deployment.

Create a CivitAI API token

  1. Open CivitAI and click your profile picture.
  2. Open Account Settings using the cog icon.
  3. Scroll to API Keys and choose Add API Key.
  4. Give the key a name and copy it somewhere private.

Configure the template before deploying

  1. On Runpod, click Edit Template before you deploy.
  2. Expand the environment variables section.
  3. Paste your API token into civitai_token. Keep this key private.
  4. Enter LoRA model-version IDs in CIVITAI_LORAS. For multiple files, separate the IDs with commas.
  5. For checkpoints, use CIVITAI_CHECKPOINTS instead. Replace any replace_with_ids placeholder with your selected IDs; these fields take ID lists, not true or false.
  6. Save and deploy. The downloader fetches the requested files during startup.
Text
VERSION_ID_1,VERSION_ID_2

Use the model-version ID

Select the version you want on the CivitAI model page. Use the number after modelVersionId= in that version's URL, not the model ID after /models/. A direct download URL uses the same version ID after /api/download/models/. Enter only the numeric IDs, not full URLs.

LoRAs download into models/loras; checkpoints download into models/checkpoints. Leave the ID fields empty to skip those downloads. An unchanged replace_with_ids placeholder is also skipped.

If the settings are missing

On these four templates, add the exact variable names above if the fields are missing. Older saved settings may use LORAS_IDS_TO_DOWNLOAD, CHECKPOINT_IDS_TO_DOWNLOAD or SDXL_MODEL_IDS_TO_DOWNLOAD. They still work, but use CIVITAI_LORAS and CIVITAI_CHECKPOINTS for new settings. If both old and new ID fields contain values, the new names take priority.

Keep the token private

Enter your key only in the intended template setting. Keep it out of workflow files, screenshots and support messages. After the downloads finish, select the downloaded model files in the workflow's loaders.

Continue with Load a workflow JSON.