InsecurePlatformWarning: A true SSLContext object is not available

I was using Python’s Requests module at a recent client engagement. I and ran into this error:

requests/packages/urllib3/util/ InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see

What worked for me was to do this:

pip install requests[security]

To add this to your requirements.txt on GitHub


I typed this up because I noticed there are a few of other workarounds listed on the Internet – including upgrading your Python version (recommended if possible), installing PyOpenSSL and even downgrading(?!) your Requests version to suppress the warning.

Arunkumar Muralidharan

I want to find out what conditions produce remarkable software. A few years ago, I chose to work as the first professional tester at a startup. I successfully won credibility for testers and established a world-class team. I have lead the testing for early versions of multiple products. Today, I run Qxf2 Services. Qxf2 provides software testing services for startups. If you are interested in what Qxf2 offers or simply want to talk about testing, you can contact me at: I like testing, math, chess and dogs.

Be First to Comment

Leave a Reply

Your email address will not be published.