What the msvcp140.dll Error Means
The msvcp140.dll is missing error (or "msvcp140.dll is absent") is a Windows system message that appears when attempting to run a program compiled using Microsoft Visual C++ 2015–2022. The msvcp140.dll file is part of the Microsoft Visual C++ Redistributable—a set of runtime libraries required for applications written in C++.
The full error text usually looks like this:
The program can't start because msvcp140.dll is missing from your computer. Try reinstalling the program to fix this problem.
The error occurs at the stage of launching the executable file (.exe) before the program window appears. Symptoms:
- Double-clicking a program's shortcut displays a dialog box with the message.
- The program crashes or fails to launch entirely.
- In some cases, the error may appear when installing other software that depends on this library.
Causes
- Visual C++ Redistributable 2015–2022 package is not installed—the program requires the library, but the corresponding version of the package is missing from the system.
- Corruption or accidental deletion of the
msvcp140.dllfile—antivirus software, disk cleanup, or a system error may have deleted or damaged the file. - Version conflict—an outdated version of Visual C++ Redistributable (e.g., only the 2015 version) is installed, but the program requires a newer one (2015–2022).
- Antivirus/firewall blocks the file—the security system mistakenly identifies
msvcp140.dllas malicious and quarantines it. - Incorrect program installation—the installer failed to unpack or register the necessary dependencies.
- Corruption of Windows system files—errors in the registry or system libraries prevent the DLL from loading.
Solution 1: Install Visual C++ Redistributable (Primary Solution)
This is the most reliable and safe method—installing the official package from Microsoft guarantees compatibility and automatic updates.
Step 1: Determine System and Program Architecture
- Press
Win + R, typemsinfo32, and press Enter. - In the "System Information" window, find the System Type entry.
- If it says x64-based PC—you have 64-bit Windows.
- If it says x86-based PC—you have 32-bit Windows.
- Also check the architecture of the program that shows the error (usually indicated on the developer's website or in the shortcut properties).
Step 2: Download the Official Package
- Go to the Microsoft download page:
Latest supported Visual C++ Redistributable - Find the Visual Studio 2015, 2017, 2019, and 2022 section.
- Download both packages (recommended):
vc_redist.x86.exe—for 32-bit programs (on any Windows).vc_redist.x64.exe—for 64-bit programs (only on 64-bit Windows).
⚠️ Important: If unsure, install both. This will not harm the system.
Step 3: Install the Packages
- Run the downloaded installer (e.g.,
vc_redist.x64.exe). - Click Install (if a UAC prompt appears—agree).
- Accept the license agreement and complete the installation.
- Repeat for the other package (if you downloaded both).
- Restart your computer for changes to take effect completely.
Step 4: Verify
Run the program that previously showed the error. In 90% of cases, this method resolves the issue.
Solution 2: Manual File Replacement (Only if Installing Redistributable Didn't Help)
⚠️ Important: This method is not recommended by Microsoft and may cause issues with updates or compatibility. Use only as a last resort if installing the package is impossible.
Steps:
- Download the
msvcp140.dllfile only from trusted sources (e.g., from the official Microsoft SDK or from another working PC with the same Windows version). - Determine where to copy the file:
- If the error is in a specific program—copy
msvcp140.dllinto its executable folder (usuallyC:\Program Files\...orC:\Program Files (x86)\...). - If the error is system-wide—for 64-bit Windows:
C:\Windows\System32\—for 64-bit programs.C:\Windows\SysWOW64\—for 32-bit programs. For 32-bit Windows—onlyC:\Windows\System32\.
- If the error is in a specific program—copy
- After copying, restart your computer.
💡 Tip: After manual replacement, still install the Visual C++ Redistributable (Solution 1) to avoid future issues.
Solution 3: Check System File Integrity
Corruption of Windows system components can interfere with DLL operation. Use built-in utilities:
- Open Command Prompt or PowerShell as Administrator (Win+X → "Windows PowerShell (Admin)").
- Run the commands sequentially:
DISM /Online /Cleanup-Image /RestoreHealth sfc /scannowDISMrepairs the Windows image.sfcscans and fixes protected system files.
- After completion, restart your computer and test the program.
Solution 4: Reinstall the Problematic Program
If the error occurs only in one program:
- Uninstall it via Control Panel → Programs and Features.
- Download a fresh copy from the developer's official website.
- Install with administrator privileges (right-click the installer → "Run as administrator").
- If the installer requires Visual C++ Redistributable—agree to install it.
Solution 5: Update Windows
Microsoft periodically releases updates that include newer versions of Visual C++ libraries.
- Open Windows Settings (
Win + I). - Go to Update & Security → Windows Update.
- Click Check for updates.
- Install all available updates, including optional ones.
- Restart your computer.
Prevention
To avoid the error recurring:
- Regularly install Windows updates—they often include Visual C++ library updates.
- Do not manually delete files from
System32andSysWOW64folders. - Use only official program installers—they automatically check and install dependencies.
- When installing games/programs that require Visual C++, ensure the redistributable package is already installed (or install it beforehand).
- Do not download DLL files from dubious websites—this risks virus infection.