Installing aider

Install git

Make sure you have git installed. Here are instructions for installing git in various environments.

Get your API key

To work with OpenAI’s models like GPT-4o or GPT-3.5 you need a paid OpenAI API key. Note that this is different than being a “ChatGPT Plus” subscriber.

To work with Anthropic’s models like Claude 3.5 Sonnet you need a paid Anthropic API key.

Windows install

# Install aider
py -m pip install aider-chat

# To work with GPT-4o:
$ aider --4o --openai-api-key sk-xxx...

# To work with Claude 3.5 Sonnet:
$ aider --sonnet --anthropic-api-key sk-xxx...

Mac/Linux install

# Install aider
python -m pip install aider-chat

# To work with GPT-4o:
$ aider --4o --openai-api-key sk-xxx...

# To work with Claude 3.5 Sonnet:
$ aider --sonnet --anthropic-api-key sk-xxx...

Using a Python virtual environment is recommended. Or, you could use pipx to install aider once for your whole system.

Running aider as a module

In some environments the aider command may not be available on your shell path. You can also run aider as a module, like this:

$ python -m aider (...rest of aider args...)

Working with other LLMs

Aider works best with GPT-4o & Claude 3.5 Sonnet and can connect to almost any LLM.

You are done!

There are some optional install steps you could consider. See the usage instructions to start coding with aider.