Unable to connect using code from docs


Trying to simply connect to the API, but receiving the error: requests.exceptions.SSLError: HTTPSConnectionPool(host=‘controller.asia-southeast1-gcp.pinecone.io’, port=443): Max retries exceeded with url: /actions/whoami (Caused by SSLError(SSLCertVerificationError(1, ‘[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:1122)’)))

My code looks like this (with key and env defined elsewhere):

import pinecone
pinecone.init(api_key=PINECONE_KEY, environment=PINECONE_ENV)

Please help!

1 Like

Hi Seth,

Are you running on macOS? Depending on your python install, you may need to run the “Install Certificates.command” found in Macintosh HD > Applications > Python

If not, let me know your OS, Python version and installation type (installer, homebrew, etc)



I’m having the same issue on Windows, python 3.11 with pip. I do have a firewall installed on my PC. How can I ignore SSL for the request or send my self signed certificate?
Or what would be the url I could add to my exception list so that it can get through the firewall?

1 Like

I’m also running into this issue from a docker image running on a mac

Found my issue! I didn’t realise each project has a different API key :man_facepalming: