Python 3.7 anaconda environment - import _ssl DLL load fail error

You can try to set system environment variables, like "C:\Python\Anaconda3;C:\Python\Anaconda3\Scripts; C:\Python\Anaconda3\Library\bin;".

Only "C:\Python\Anaconda3\Scripts;" is not enough, and it works to me.


I had the same issue on Windows 10 Pro x64 and PyCharm CE 2018.3

A solution that worked for me: Re-install Anaconda3 for all users (with Admin priveledges) and choose "add python.exe to Path" (even though it is nor recommended). Then PyCharm connected successfully without this error.

A work around that also worked: Use another environment (pyenv or conda). It worked for me when I faced the same issue on

Some other suggestions I saw on Internet: run Anaconda3\Scripts>conda update --all but this threw the HTTP connection error rises, which might be related.


I have answerd this here, to my understanding this error is caused by the missing/misplacement of libcrypto file in anaconda3/DLLs folder:

From anaconda3\Library\bin copy below files and paste them in anaconda3/DLLs:

-   libcrypto-1_1-x64.dll
-   libssl-1_1-x64.dll 

This can be fixed by manually adding in the PATH variables in PyCharm to the console.

  1. Open your Anaconda cmd
  2. Activate your Conda environment
  3. Get the full PATH value by typing echo %PATH%
    • if you are on Windows 7/can't copy the output, cd the cmd to your desktop and type echo %PATH% > path_val.txt
    • this will create a txt file so you can copy/paste the values easier.
  4. In PyCharm, go to Settings -> Build, Execution, Deployment -> Console -> Python Console -> click the folder on the right of Environment variables.
  5. Click the plus button to add a new Environment Variable
    • The name should be PATH
    • The value is the entire output from the echo %PATH% command above.
  6. Click OK, then apply.