Why Install Stable Diffusion Locally?
Running Stable Diffusion on your own computer has many advantages: unlimited generation (no credits), full privacy (images are not uploaded anywhere), full control (any model and LoRA you want), no NSFW restrictions, and no internet connection required. The downside is that it requires a powerful GPU. You can compare Stable Diffusion with other AI image tools on [tasarim.ai](https://tasarim.ai).
System Requirements
### Minimum Requirements (SD 1.5) - **GPU:** NVIDIA RTX 2060 (6GB VRAM) or higher - **RAM:** 16GB - **Storage:** 20GB free space (excluding models) - **OS:** Windows 10/11, Linux, or macOS (Apple Silicon)
### Recommended Requirements (SDXL) - **GPU:** NVIDIA RTX 3060 (12GB VRAM) or higher - **RAM:** 32GB - **Storage:** 100GB+ SSD (including models) - **OS:** Windows 11 or Linux (Ubuntu 22.04+)
### AMD and Apple Silicon - AMD GPUs offer limited support via DirectML - Apple Silicon (M1/M2/M3) works on macOS with MPS backend - Best experience is achieved with NVIDIA GPUs
AUTOMATIC1111 Installation (Windows)
AUTOMATIC1111 is the most popular Stable Diffusion web interface:
### Step 1: Prerequisites 1. Download and install **Python 3.10.6** (python.org) — check "Add to PATH" 2. Download and install **Git** (git-scm.com) 3. Install the latest **NVIDIA CUDA Toolkit** 4. Update **NVIDIA GPU drivers** (at least 525.xx)
### Step 2: Installation 1. Open command prompt (CMD or PowerShell) 2. Navigate to your desired folder: `cd C:\AI` 3. Clone the repository: `git clone https://github.com/AUTOMATIC1111/stable-diffusion-webui.git` 4. Enter the folder: `cd stable-diffusion-webui` 5. Run `webui-user.bat` 6. On first run, required packages are automatically downloaded (may take 20-30 minutes) 7. When "Running on local URL: http://127.0.0.1:7860" appears, open it in your browser
### Step 3: Model Download 1. Go to civitai.com 2. Our recommended starter models: - **SD 1.5:** Realistic Vision v5.1, DreamShaper v8 - **SDXL:** Juggernaut XL, RealVisXL 3. Copy the downloaded .safetensors file to the `models/Stable-diffusion/` folder 4. Select the model from the top-left corner of the web interface
ComfyUI Installation
ComfyUI is an advanced node-based interface. It offers more complex workflows and lower VRAM usage:
### Installation 1. `git clone https://github.com/comfyanonymous/ComfyUI.git` 2. `cd ComfyUI` 3. `pip install -r requirements.txt` 4. Start with `python main.py` 5. Place models in the `models/checkpoints/` folder
### ComfyUI vs AUTOMATIC1111 - **AUTOMATIC1111:** Easier interface, ideal for beginners - **ComfyUI:** Uses less VRAM, complex workflows with node system, faster
Optimization Tips
### VRAM Savings - Use `--medvram` or `--lowvram` parameters (in webui-user.bat) - Enable xformers: `--xformers` - Use FP16 precision (default) - Activate Tiled VAE decode
### Speed Optimization - Add the `--opt-sdp-attention` parameter - Keep batch size at 1 (with low VRAM) - Keep sampling steps between 20-25 - Use DPM++ 2M Karras sampler (speed/quality balance)
### Storage Management - Models are large files: SD 1.5 ~2GB, SDXL ~6GB - LoRAs are smaller: 10-200MB - Regularly clean generated images - Consider using an external HDD/SSD
LoRA and Extension Installation
### Downloading and Using LoRAs 1. Download the LoRA file from civitai.com 2. Copy to the `models/Lora/` folder 3. To use in prompt: add as `<lora:filename:0.7>` 4. Adjust the weight (0.7) between 0.3-1.0
### Popular Extensions - **ControlNet:** Precise visual control (pose, edge, depth) - **Adetailer:** Automatic face and hand detail improvement - **Tiled Diffusion:** Very high resolution generation - **Regional Prompter:** Apply different prompts to different regions of the image - **Roop:** Face swap
To install extensions: Extensions tab > "Install from URL" > paste the GitHub URL.
Troubleshooting
### Common Issues and Solutions
**"CUDA out of memory" error:** - Lower the resolution (512x512) - Add the `--medvram` parameter - Set batch size to 1 - Close other GPU-using applications
**"No module named 'xxx'" error:** - Delete the venv folder and restart - Check Python version (3.10.6 recommended)
**Black/empty image generation:** - Check the VAE setting - Add the `--no-half-vae` parameter - Try a different model
**Web interface won't open:** - Check firewall settings - Try a different port: `--port 7861`
Frequently Asked Questions
**Will it damage my computer?** No, Stable Diffusion will not damage your computer. However, temperatures may rise since it heavily uses the GPU. We recommend monitoring GPU temperature and keeping it below 85°C.
**I don't have an NVIDIA GPU — what can I do?** AMD GPUs work with limited functionality via DirectML. Apple Silicon (M1+) works with MPS backend. Alternatively, you can use cloud GPU services like Google Colab, RunPod, or Vast.ai.
**How much disk space is needed?** Base installation ~10GB, one model ~2-6GB, LoRAs ~50-200MB. We recommend planning 50-100GB of space with multiple models and LoRAs. You can also explore cloud alternatives on the [tasarim.ai/kesfet](https://tasarim.ai/kesfet) page.
**How do I update?** For AUTOMATIC1111: navigate to the folder and run `git pull`. The same method applies for ComfyUI. Follow civitai.com for model updates.