Free | No tracking | Every fact with a source|German and English

Error / Installation

pip: Microsoft Visual C++ 14.0 or greater is required

pip wants to build a package from source and can’t find a C++ compiler for it.

The message

error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/ … ERROR: Failed building wheel for insightface

Affects: Python, ComfyUI, AUTOMATIC1111 Stable Diffusion WebUI, Stable Diffusion WebUI Forge, TextGen (text-generation-webui), Coqui TTS (Idiap fork) with XTTS-v2

Why is this happening?

Some packages (for example insightface for Face-Swap nodes) contain C/C++ code. If there is no prebuilt package (wheel) for your Python version, pip compiles it itself and needs the Microsoft C++ Build Tools for that. This happens especially often with very new Python versions.

How to fix it

  1. Check whether you’re using the Python version recommended by the program. With a suitable version, there is often a prebuilt wheel and you don’t need a compiler at all.
  2. Download the Build Tools from https://visualstudio.microsoft.com/visual-cpp-build-tools/ ("Download Build Tools") and start vs_BuildTools.exe.
  3. In the Visual Studio Installer, select the workload "Desktop development with C++". Keep the current MSVC build tools and the Windows SDK checked, then click "Install". Plan for at least 6 GB of disk space.
  4. Restart your PC after installation.
  5. Activate your program’s venv and update the build tools: python -m pip install --upgrade pip setuptools wheel.
  6. Repeat the original pip command.

Better not: The "Microsoft Visual C++ Redistributable" is not enough; you need the Build Tools. Also do not install precompiled wheels from unknown sites.

Set up from scratch again

If it still doesn’t work after that, a fresh setup step by step often helps:

Terms for this

Similar errors

Sources

Checked on Oct 21, 2026. Didn't help? Ask in the forum and name the graphics card, program, and the full message.