close

[Solved] pip is configured with locations that require TLS/SSL however the SSL module in Python is not available

To solve pip is configured with locations that require TLS/SSL however the SSL module in Python is not available error you need to add anaconda into the path variable and it will resolve this error.

How pip is configured with locations that require TLS/SSL however the ssl module in Python is not available Error Occurs.

I am just trying to install the module with the pip command but I am facing the following error.

pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available

Solution 1: add Anaconda to the PATH

  • First of all, you need to check conda installation path.
  • Just Open Anaconda Prompt and type this command: where conda
  • Then Press the windows key and type Open Advanced System Settings.
  • Now, Click on Environment Variables.
  • Edit Path variable.
  • And Then Add New Path. In my case
 C:\Users\ssc\Anaconda3\Scripts

 C:\Users\ssc\Anaconda3

 C:\Users\ssc\Anaconda3\Library\bin
  • Just add above 3 in PATH variable.
  • Then, Open Command Prompt and Check Versions
  • And type conda install anaconda-navigator in cmd then press y
  • Now your error must be solved.

Solution 2: install OpenSSL

Here pip doesn’t work because of ssl and you ask to install ssl, with pip.

  1. first, install OpenSSL, please refer to this page
  2. install python and ./configure --with-openssl=/home/username/openssl. download python source from https://www.python.org/downloads/source/ such as Python-x.x.x.tgz, then tar -xvf Python-x.x.x.tgz, and cd Python-x.x.x, do /configure –with-openssl=/home/username/openssl.
  3. at last, run python3 -m ssl and nothing outputs, it’s ok.

Solution 3: install libssl-dev

If You are using Linux then Just install libssl-dev. Run this command in your terminal.

sudo apt-get install libssl-dev

And now, Your error will be solved.

Frequently Asked Questions

  1. How To Solve pip is configured with locations that require TLS/SSL however the ssl module in Python is not available Error ?

    To Solve pip is configured with locations that require TLS/SSL however the ssl module in Python is not available Error Just Open Anaconda Prompt and type this command: where conda Then Press windows key and type Open Advanced System Settings. Now, Click on Environment Variables. Edit Path variable. And Then Add New Path. In my case C:\Users\ssc\Anaconda3\Scripts; C:\Users\ssc\Anaconda3; C:\Users\ssc\Anaconda3\Library\bin; Just add above 3 in PATH variable. Then, Open Command Prompt and Check Versions And type conda install anaconda-navigator in cmd then press y Now your error must be solved.

  2. pip is configured with locations that require TLS/SSL however the ssl module in Python is not available

    To Solve pip is configured with locations that require TLS/SSL however the ssl module in Python is not available Error Just Open Anaconda Prompt and type this command: where conda Then Press windows key and type Open Advanced System Settings. Now, Click on Environment Variables. Edit Path variable. And Then Add New Path. In my case C:\Users\ssc\Anaconda3\Scripts; C:\Users\ssc\Anaconda3; C:\Users\ssc\Anaconda3\Library\bin; Just add above 3 in PATH variable. Then, Open Command Prompt and Check Versions And type conda install anaconda-navigator in cmd then press y Now your error must be solved.

Summary

The best and most effective solution is just to add an anaconda in the path variable and then retry to install the pip package will resolve your error. comment below which solution worked for you.

Also, Read

Leave a Comment