> For the complete documentation index, see [llms.txt](https://docs.openalgo.in/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.openalgo.in/installation-guidelines/getting-started/mac-os-installation/install-certifi.md).

# Install certifi

If you’re encountering, SSLCertVerificationError: \[SSL: CERTIFICATE\_VERIFY\_FAILED] certificate verify failed: unable to get local issuer certificate, is common on macOS when Python is unable to verify SSL certificates due to a missing or inaccessible certificate store. This usually affects the ability to fetch data over HTTPS, such as when attempting to download or use resources like ngrok.

\
To resolve this issue on macOS, you need to install the certificates for Python. Follow these steps:

In this example I used python3.11 as the version replace it with python3.xx version in the below commands

&#x20;**1. Locate the Correct Path of Python Installation:**

To find out where Python 3.11 is installed on your system, use the which command. Open your Terminal and type:

```
which python3.11
```

Locate and Run the Install Certificates Script:

<figure><img src="/files/aEIqVIqobMyElSR9mViP" alt=""><figcaption></figcaption></figure>

Once you have the correct path to Python 3.11, you can attempt to locate the Install Certificates.command script. Typically, if you installed Python via Homebrew, the command might not directly exist, but Python installations downloaded from the official Python website typically include it.

Assuming you installed Python using Homebrew, you might not find an Install Certificates.command. Instead, you can ensure the certificates are installed by manually installing the certifi package and configuring your environment to use it. Here’s how you can do that:

2. **Install certifi:**

```
python3.11 -m pip install certifi
```

3. **Set the SSL\_CERT\_FILE Environment Variable:**

To manually specify the certificate file for Python to use, you can set the SSL\_CERT\_FILE environment variable to point to the certifi certificate file:

```
export SSL_CERT_FILE=$(python3.11 -m certifi)
```

4. **Retry Running Your Python Code:**

After setting up the certificates through certifi, try running your Python code again. This should resolve any SSL certificate issues.<br>

If you installed Python using a method other than Homebrew and the Python installation includes the Install Certificates.command, you would typically find it in the Python application directory within /Applications/Python 3.11 or similar. If this is the case, navigate to this directory in Finder, and you should be able to run the Install Certificates.command by double-clicking on it.

Ensure that you are using the correct paths and commands based on how and where Python is installed on your system.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.openalgo.in/installation-guidelines/getting-started/mac-os-installation/install-certifi.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
