# Python.exe System Error missing python.dll

**URL:** <https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570>\
**Category:** Python Help\
**Created:** [September 24, 2023, 8:11pm UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570 "2023-09-24T20:11:59Z")\
**Posts on this page:** 19\
**Page:** 1

<div class="post-metadata">

**Author:** ![classicjonesy](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/classicjonesy/32/14866_2.png) [@classicjonesy](https://discuss.python.org/u/classicjonesy)\
**Post date:** [September 24, 2023, 8:11pm UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/1 "2023-09-24T20:11:59Z")

</div>

I have been trying to install python with “python-3.11.5-amd64” on Windows 11. But whenever it reaches the “Precompiling Standard Library” it proceeds with this Error.

“The code execution cannot proceed because python.dll was not found. Reinstalling the program may fix this problem”

Then I try re-run the installer with Repair (running as ADMIN) but I get the same error.

I’ve also tried uninstalling and reinstalling; and I get the same issue.

---

<div class="post-metadata">

**Author:** ![barry-scott](https://avatars.discourse-cdn.com/v4/letter/b/e9c0ed/32.png) [@barry-scott](https://discuss.python.org/u/barry-scott)\
**Post date:** [September 25, 2023, 6:46am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/2 "2023-09-25T06:46:06Z")

</div>

Suggest you first tell windows to uninstall this python, if it is recorded as installed.  
Delete the install .exe and download python again and try the install again using this link [https://www.python.org/ftp/python/3.11.5/python-3.11.5-amd64.exe](https://www.python.org/ftp/python/3.11.5/python-3.11.5-amd64.exe)

Let us know if this helps?

---

<div class="post-metadata">

**Author:** ![classicjonesy](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/classicjonesy/32/14866_2.png) [@classicjonesy](https://discuss.python.org/u/classicjonesy)\
**Post date:** [September 27, 2023, 6:50am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/3 "2023-09-27T06:50:32Z")

</div>

I ran CC Cleaner to fix the python references, attempted to reinstall and still errors.

 ![python-install-error](https://us1.discourse-cdn.com/flex002/uploads/python1/original/2X/2/23b55a6101e5b2fee86b5204bcf4cbf70271e96f.png)

---

<div class="post-metadata">

**Author:** ![classicjonesy](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/classicjonesy/32/14866_2.png) [@classicjonesy](https://discuss.python.org/u/classicjonesy)\
**Post date:** [September 27, 2023, 7:03am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/4 "2023-09-27T07:03:26Z")

</div>

Screenshot of my Control Panel

 ![no-python-installed](https://us1.discourse-cdn.com/flex002/uploads/python1/original/2X/4/491e8b70ae6064eb2c661584725b6a4a6fa7b116.png)

---

<div class="post-metadata">

**Author:** ![classicjonesy](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/classicjonesy/32/14866_2.png) [@classicjonesy](https://discuss.python.org/u/classicjonesy)\
**Post date:** [September 27, 2023, 8:02am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/5 "2023-09-27T08:02:32Z")

</div>

I did find that python exists in WindowsApps

```auto
Microsoft Windows [Version 10.0.22621.2283]
(c) Microsoft Corporation. All rights reserved.

C:\Windows\System32>where python.exe
C:\Users\Mike Jones\AppData\Local\Microsoft\WindowsApps\python.exe

C:\Windows\System32>

```

> <https://stackoverflow.com/questions/57485491/python-python3-executes-in-command-prompt-but-does-not-run-correctly>

I went through and disabled Python in Aliases which removed it from WindowsApps

```auto
C:\>where python.exe
INFO: Could not find files for the given pattern(s).

```

Installer is still failing though

---

<div class="post-metadata">

**Author:** ![classicjonesy](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/classicjonesy/32/14866_2.png) [@classicjonesy](https://discuss.python.org/u/classicjonesy)\
**Post date:** [September 27, 2023, 8:28am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/6 "2023-09-27T08:28:03Z")

</div>

I tried setting Everyone Permissions (from [Missing dll Error Whle installing Python 2.7 - Stack Overflow](https://stackoverflow.com/questions/17502747/missing-dll-error-whle-installing-python-2-7)) for " **C:/Users/My Account/AppData/Local**" in “ **Temp** ” but that didn’t work either

---

<div class="post-metadata">

**Author:** ![barry-scott](https://avatars.discourse-cdn.com/v4/letter/b/e9c0ed/32.png) [@barry-scott](https://discuss.python.org/u/barry-scott)\
**Post date:** [September 27, 2023, 8:48am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/7 "2023-09-27T08:48:54Z")

</div>

Have you installed the windows app store python as well?

You may be finding that the app store version is conflicting with the [python.org](http://python.org) version.

Check in the app store and uninstall python from there if it is installed.

I recommend you use the [python.org](http://python.org) versions, not the app store version.

---

<div class="post-metadata">

**Author:** ![classicjonesy](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/classicjonesy/32/14866_2.png) [@classicjonesy](https://discuss.python.org/u/classicjonesy)\
**Post date:** [September 27, 2023, 9:11am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/8 "2023-09-27T09:11:10Z")

</div>

This was a fresh install of Windows using a Media USB I did last week so I’m really confused on why I can’t install it.

---

<div class="post-metadata">

**Author:** ![selectronic-dave](https://avatars.discourse-cdn.com/v4/letter/s/90db22/32.png) [@selectronic-dave](https://discuss.python.org/u/selectronic-dave)\
**Post date:** [November 6, 2023, 4:36am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/9 "2023-11-06T04:36:27Z")

</div>

Hi,

I am getting the same issue as Michael. I downloaded `python-3.12.0-amd64.exe` from python dot org. Attempts to install for all users (and running as administrator) result in the same System Error pop-up that Michael gets (except that “python312.dll” is missing) The pop-up appears three times and then the installer reports success. When then I attempt to run python the missing DLL pop-up appears . A search of my system for a file named `python312.dll` yields nothing.

When I install for just the user the process completes but then attempts to run python trigger the System Error pop-up.

The machine was previously running python 3.10.7 (got via installer from python dot org). This had been uninstalled.

Below is a snippet of the log file that I think corresponds with the System Error pop-ups. I can provide the whole log if needed.

Thanks,  
Dave

```auto
[12BC:65C0][2023-11-06T14:57:40]i001: Burn v3.14.0.5722, Windows v10.0 (Build 19045: Service Pack 0), path: C:\Windows\Temp\{F34DC45E-F74E-4B59-B4CC-4C6C66A97D2D}\.cr\python-3.12.0-amd64.exe
...
[12BC:65C0][2023-11-06T14:58:13]i301: Applying execute package: path_JustForMe, action: Uninstall, path: (null), arguments: ' ARPSYSTEMCOMPONENT="1" MSIFASTINSTALL="7" TARGETDIR="C:\Program Files\Python312" OPTIONALFEATURESREGISTRYKEY="Software\Python\PythonCore\3.12\InstalledFeatures"'
[12BC:65C0][2023-11-06T14:58:13]i319: Applied execute package: path_JustForMe, result: 0x0, restart: None
[66F4:6310][2023-11-06T14:58:13]i301: Applying execute package: compileall_AllUsers, action: Install, path: C:\ProgramData\Package Cache\9779F8E04E7A01A68A3B636AE4B5212AA46575B2\py.exe, arguments: '"C:\ProgramData\Package Cache\9779F8E04E7A01A68A3B636AE4B5212AA46575B2\py.exe" -3.12 -E -s -Wi "C:\Program Files\Python312\Lib\compileall.py" -f -x "bad_coding|badsyntax|site-packages|py2_|lib2to3\\tests|venv\\scripts" "C:\Program Files\Python312\Lib"'
[66F4:6310][2023-11-06T14:58:30]e000: Error 0xc0000135: Process returned error: 0xc0000135
[66F4:6310][2023-11-06T14:58:30]e000: Error 0xc0000135: Failed to execute EXE package.
[12BC:65C0][2023-11-06T14:58:30]e000: Error 0xc0000135: Failed to configure per-machine EXE package.
[12BC:65C0][2023-11-06T14:58:30]w350: Applied non-vital package: compileall_AllUsers, encountered error: 0xc0000135. Continuing...
[66F4:6310][2023-11-06T14:58:30]i301: Applying execute package: compileallO_AllUsers, action: Install, path: C:\ProgramData\Package Cache\9779F8E04E7A01A68A3B636AE4B5212AA46575B2\py.exe, arguments: '"C:\ProgramData\Package Cache\9779F8E04E7A01A68A3B636AE4B5212AA46575B2\py.exe" -3.12 -O -E -s -Wi "C:\Program Files\Python312\Lib\compileall.py" -f -x "bad_coding|badsyntax|site-packages|py2_|lib2to3\\tests|venv\\scripts" "C:\Program Files\Python312\Lib"'
[66F4:6310][2023-11-06T14:58:32]e000: Error 0xc0000135: Process returned error: 0xc0000135
[66F4:6310][2023-11-06T14:58:32]e000: Error 0xc0000135: Failed to execute EXE package.
[12BC:65C0][2023-11-06T14:58:32]e000: Error 0xc0000135: Failed to configure per-machine EXE package.
[12BC:65C0][2023-11-06T14:58:32]w350: Applied non-vital package: compileallO_AllUsers, encountered error: 0xc0000135. Continuing...
[66F4:6310][2023-11-06T14:58:32]i301: Applying execute package: compileallOO_AllUsers, action: Install, path: C:\ProgramData\Package Cache\9779F8E04E7A01A68A3B636AE4B5212AA46575B2\py.exe, arguments: '"C:\ProgramData\Package Cache\9779F8E04E7A01A68A3B636AE4B5212AA46575B2\py.exe" -3.12 -OO -E -s -Wi "C:\Program Files\Python312\Lib\compileall.py" -f -x "bad_coding|badsyntax|site-packages|py2_|lib2to3\\tests|venv\\scripts" "C:\Program Files\Python312\Lib"'
[66F4:6310][2023-11-06T14:58:33]e000: Error 0xc0000135: Process returned error: 0xc0000135
[66F4:6310][2023-11-06T14:58:33]e000: Error 0xc0000135: Failed to execute EXE package.
[12BC:65C0][2023-11-06T14:58:33]e000: Error 0xc0000135: Failed to configure per-machine EXE package.
[12BC:65C0][2023-11-06T14:58:33]w350: Applied non-vital package: compileallOO_AllUsers, encountered error: 0xc0000135. Continuing...
[12BC:65C0][2023-11-06T14:58:33]i372: Session end, registration key: SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{cf9c4d97-48a7-4a27-b9fc-91b88a803c40}, resume: ARP, restart: None, disable resume: No
[12BC:65C0][2023-11-06T14:58:33]i371: Updating session, registration key: SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{cf9c4d97-48a7-4a27-b9fc-91b88a803c40}, resume: ARP, restart initiated: No, disable resume: No
[12BC:65C0][2023-11-06T14:58:33]i399: Apply complete, result: 0x0, restart: None, ba requested restart: No
[12BC:5DA0][2023-11-06T14:58:33]i000: Failed to read LongPathsEnabled value: error code 0
[12BC:65C0][2023-11-06T15:09:19]i500: Shutting down, exit code: 0x0
[12BC:65C0][2023-11-06T15:09:19]i410: Variable: ActionLikeInstallation = Setup
[12BC:65C0][2023-11-06T15:09:19]i410: Variable: ActionLikeInstalling = Installing
[12BC:65C0][2023-11-06T15:09:19]i410: Variable: AppendPath = 0
...
[12BC:65C0][2023-11-06T15:09:19]i007: Exit code: 0x0, restarting: No

```

---

<div class="post-metadata">

**Author:** ![barry-scott](https://avatars.discourse-cdn.com/v4/letter/b/e9c0ed/32.png) [@barry-scott](https://discuss.python.org/u/barry-scott)\
**Post date:** [November 6, 2023, 4:17pm UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/10 "2023-11-06T16:17:04Z")

</div>

What version of Windows are you install python on?

---

<div class="post-metadata">

**Author:** ![selectronic-dave](https://avatars.discourse-cdn.com/v4/letter/s/90db22/32.png) [@selectronic-dave](https://discuss.python.org/u/selectronic-dave)\
**Post date:** [November 6, 2023, 9:08pm UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/11 "2023-11-06T21:08:06Z")

</div>

Hi Barry,

Windows 10 Pro  
Version 22H2  
OS Build 19045.3570

---

<div class="post-metadata">

**Author:** ![barry-scott](https://avatars.discourse-cdn.com/v4/letter/b/e9c0ed/32.png) [@barry-scott](https://discuss.python.org/u/barry-scott)\
**Post date:** [November 6, 2023, 9:50pm UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/12 "2023-11-06T21:50:33Z")

</div>

Ok I’d not expect any issue with Windows 10.

I wonder if your anti-virus software is getting in the way?  
Do you have any “enterprise security” tools on your PC?

Basically is there a third party that is breaking things?

---

<div class="post-metadata">

**Author:** ![swills1](https://avatars.discourse-cdn.com/v4/letter/s/e8c25b/32.png) [@swills1](https://discuss.python.org/u/swills1)\
**Post date:** [November 7, 2023, 3:51am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/13 "2023-11-07T03:51:41Z")

</div>

My laptop itself is on Windows 11 and I can install Python 3.12 without issue. I wouldn’t run as administrator if you can help it. For both people having trouble, I would completely uninstall, reboot, install from the Python website. Tell it to set the env variables.

> **[Download Python](https://www.python.org/downloads/)**
>
> The official home of the Python Programming Language

---

<div class="post-metadata">

**Author:** ![selectronic-dave](https://avatars.discourse-cdn.com/v4/letter/s/90db22/32.png) [@selectronic-dave](https://discuss.python.org/u/selectronic-dave)\
**Post date:** [November 8, 2023, 10:14pm UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/14 "2023-11-08T22:14:18Z")

</div>

Thanks Barry and Steven.  
I don’t think there is enterprise security getting in the way but would not be surprised if Windows misconfiguration was my issue. I have now got a successful installation using pyenv-win.

---

<div class="post-metadata">

**Author:** ![classicjonesy](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/classicjonesy/32/14866_2.png) [@classicjonesy](https://discuss.python.org/u/classicjonesy)\
**Post date:** [November 9, 2023, 5:48am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/15 "2023-11-09T05:48:02Z")

</div>

I actually got my Python installed; I had to check “Install with Admin Permissions” and it worked

```auto
python -V
Python 3.12.0

```

---

<div class="post-metadata">

**Author:** ![michael\_deutsch](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/michael_deutsch/32/16215_2.png) [@michael\_deutsch](https://discuss.python.org/u/michael_deutsch)\
**Post date:** [December 3, 2023, 2:00pm UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/16 "2023-12-03T14:00:30Z")

</div>

Anyone have any ideas for how to help resolve this? I’m getting the exact same issues. I’ve tried uninstalling/reinstalling and restarting my computer multiples times. This happens when I try to install as admin (for all users) or just for my user. I’m downloading the official version (python-3.12.0-amd64.exe) from [python.org](http://python.org).  
Nothing’s worked!

If it may provide any context: I was previously getting a different error

```auto
Error 0x80070643: Failed to uninstall MSI package.
Error 0x80070643: Failed to configure per-user MSI package.
Error 0x80070643: Failed to execute MSI package.`

```

and I’m not sure what changed that now it’s become this one, where the dialog pops up with a failure message (that the dll is missing) but then I see the “Successfully installed” screen. However, any attempts to use Python fail due to the missing dlls.

It may have something to do with some corrupted Registry keys maybe? Any thoughts about how to fix that if it’s related? I also had tried installing via winget – don’t know if that may be related.

---

<div class="post-metadata">

**Author:** ![michael\_deutsch](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/michael_deutsch/32/16215_2.png) [@michael\_deutsch](https://discuss.python.org/u/michael_deutsch)\
**Post date:** [December 5, 2023, 11:57am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/17 "2023-12-05T11:57:01Z")

</div>

I couldn’t figure out how to resolve it other than reinstalling Windows – which worked 🤷

---

<div class="post-metadata">

**Author:** ![AngelPlayz](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/angelplayz/32/18627_2.png) [@AngelPlayz](https://discuss.python.org/u/AngelPlayz)\
**Post date:** [March 19, 2024, 3:26am UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/18 "2024-03-19T03:26:50Z")

</div>

I had the same issue, and weirdly enough, I think it’s the new Python installer what’s causing the issue. I went back and downloaded Python 3.11.5 instead of 3.12 onwards. Somehow, that did the trick, which got me thinking it might be the new version that’s causing the issue.

---

<div class="post-metadata">

**Author:** ![Perevodildo](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/perevodildo/32/35270_2.png) [@Perevodildo](https://discuss.python.org/u/Perevodildo)\
**Post date:** [April 16, 2026, 8:04pm UTC](https://discuss.python.org/t/python-exe-system-error-missing-python-dll/34570/19 "2026-04-16T20:04:27Z")

</div>

Solved! For me, the problem occurred after I switched from individual installations to pyenv-win for more flexibility. I uninstalled the old versions, but the windows PATH was still trying to execute them even though the files are no longer there, so I first removed any old python mentions from “Control panel \> Edit the system environment variables” and then set the new path to python installation in the pyenv-win directory with

`setx PATH "%PATH%;C:\Users\*your username*.pyenv\pyenv-win\shims"`
