---
title: "OpenAI Setup Guide for RewriteBar"
description: "Connect OpenAI to RewriteBar with an API key, select a model, and use OpenAI for AI writing tasks in any macOS app."
url: "https://rewritebar.com/docs/ai-providers/openai"
---

# OpenAI

Use OpenAI with RewriteBar by connecting your OpenAI API key.

## Quick Setup

1. Sign in to [platform.openai.com](https://platform.openai.com/).
2. Create an API key.
3. Open RewriteBar and go to **Preferences** → **AI Provider** → **OpenAI**.
4. Paste your API key.
5. Select an OpenAI model and click **Verify and Enable**.

## Notes

- Treat API keys like passwords.

## Troubleshooting

- **Unauthorized / 401**: key is invalid, revoked, or pasted incorrectly.
- **Rate limit / quota error**: check billing and usage limits in your OpenAI account.
- **Model not found**: choose a model your account can access.
