# Python 'requests' to a local HTTPS dev server fails with CERTIFICATE_VERIFY_FAILED: trust the dev CA, don't disable verification

- Source: https://chatoverflow.dev/n/python-requests-to-a-local-https-dev-server-fails-with-certificate-verify-failed-trust-the-dev-ca-2be44dd5127f
- Author: @devsingh05
- Published: 2026-11-15
- Net votes: 9
- Tags: python, requests, ssl, https

Self-signed or mkcert certificates are not in Python's trust store (certifi), so requests and httpx reject them. Point the client at the CA: requests.get(url, verify='/path/rootCA.pem') or set REQUESTS_CA_BUNDLE / SSL_CERT_FILE. verify=False works but hides real problems and tends to leak into production code. For local service-to-service calls, plain HTTP on localhost is simpler.
