---
title: "Zed Editor API: Add FreeTheAI as an OpenAI Compatible Provider"
description: "Use AI models in Zed's agent panel with FreeTheAI. Add an OpenAI compatible provider from Agent Settings or settings.json."
url: https://freetheai.org/setup/zed
language: en
updated: 2026-09-29
---

# Zed Editor API: Add FreeTheAI as an OpenAI Compatible Provider

Zed adds FreeTheAI as an OpenAI compatible LLM provider for the agent panel.

## Settings

- Provider: `OpenAI (compatible)`
- API URL: `https://api.freetheai.org/v1`
- Model ID: `glm-5.3`
- API key: `your FreeTheAI key (ftai_..., 53 characters)`

## Steps

1. **Open Agent Settings.** Press Ctrl+Shift+P (Cmd+Shift+P on Mac) and run agent: open settings.
2. **Add the provider.** Under LLM Providers press Add Provider, choose OpenAI, and enter the provider name, API URL, model ID, context window (for example 128000), and your key. Save.
3. **Or use settings.json.** The same provider in Zed's settings.json. Zed then reads the key from the FREETHEAI_API_KEY environment variable, or from the key you saved in Agent Settings.

```json
{
  "language_models": {
    "openai_compatible": {
      "FreeTheAI": {
        "api_url": "https://api.freetheai.org/v1",
        "available_models": [
          { "name": "glm-5.3", "display_name": "GLM 5.3", "max_tokens": 128000 }
        ]
      }
    }
  }
}
```

## Troubleshooting

**Where is Add Provider in Zed?**

Press Ctrl+Shift+P (Cmd+Shift+P on Mac) and run agent: open settings. Under LLM Providers press Add Provider, choose OpenAI under compatible APIs, fill it in, and press Save Provider.

**I do not see an Add Provider button. Why?**

Your Zed is out of date. Update it, or add the provider to settings.json as shown above.

**Why do I get a 401 error?**

The key is wrong or incomplete. Paste the whole ftai_ key (53 characters).

**Why do I get a 403 error?**

A 403 usually means the account follows no provider of that model, or your email is not confirmed. Follow a provider on freetheai.org/providers, then try again.

**The model is busy or the reply is empty. What should I do?**

Try again, or switch to another model. freetheai.org/status shows which models are up.

Checked: Checked against Zed's docs (OpenAI-compatible endpoints) on 2026-09-29.
