Voice and AI

How to Connect ChatGPT to Home Assistant

Connect ChatGPT to Home Assistant with the OpenAI integration and an API key, control costs and exposed devices, and keep locks and alarms out of reach.

On this page
  1. What you need
  2. Step 1: Add the OpenAI integration
  3. Step 2: Make it your assistant’s conversation agent
  4. Step 3: Choose what it can see
  5. What it costs
  6. Other features
  7. Safety
  8. Common misconceptions

ChatGPT can act as a conversation agent in Home Assistant’s Assist. The connection uses OpenAI’s API through the official OpenAI integration, not the ChatGPT app. That means you need an API key and prepaid credit, which are separate from a ChatGPT Plus subscription.

What you need

  • An OpenAI platform account and an API key, created at platform.openai.com.
  • Prepaid API credit. ChatGPT Plus does not include API credit.
  • A Home Assistant install with Assist set up. The text chat in Assist works without a voice satellite.

Step 1: Add the OpenAI integration

  1. Go to Settings > Devices & services > Add integration and choose OpenAI.
  2. Paste your API key.
  3. Open the integration’s options. Here you can edit the instructions prompt, pick a model and set Control Home Assistant to Assist.

The default model has changed over time, so check the model list in the options rather than trusting an older guide. Small models suit voice, because they respond quickly and cost less per request.

Step 2: Make it your assistant’s conversation agent

Go to Settings > Voice assistants, add an assistant or open an existing one, and set its conversation agent to OpenAI.

Turn on Prefer handling commands locally as well. Simple commands, such as turning off a light, are then handled by Home Assistant’s built-in agent. Those commands skip the API, which is faster and free. Only requests the built-in agent does not understand go to OpenAI. If a phrase you use often still reaches the model, a custom voice command can handle it locally.

Step 3: Choose what it can see

The model only sees and controls exposed entities. Each request includes the list of exposed entities, so cost grows with the number of entities you expose. Exposing hundreds of entities raises the cost and can make the model less accurate. Expose the devices you actually want to talk about, and leave the rest out.

What it costs

Typical home use costs cents to a few dollars a month. The total depends on the model you choose and how often you use it.

To keep costs predictable:

  • Set a spending limit in the OpenAI dashboard.
  • Keep the API key secret. Anyone with the key can spend your credit.

Other features

  • Actions: depending on the release, the integration can offer optional web search, image generation and file or image analysis through actions. Features vary by release, so check the options for your version.
  • Continued conversation: added in 2025, the assistant can keep listening when its reply ends in a question.
  • Extended OpenAI Conversation: a HACS integration that adds custom functions and works with OpenAI-compatible local servers.
  • The ChatGPT app: it can reach Home Assistant only through the Home Assistant MCP Server and ChatGPT connectors or developer mode. This route is uncertain and changing, so check the current documentation before you try it.

Safety

LLMs can misread a request, and a misread command can switch the wrong device. Do not expose locks, alarms or garage doors to the assistant.

The integration is not local. Requests go to OpenAI, and the entities you expose are part of what gets sent. If that matters to you, expose only what you are comfortable sharing. For a fully local option, see AI in Home Assistant, which covers local models and their trade-offs.

Common misconceptions

  • ChatGPT Plus does not include API credit. The API is billed separately.
  • The integration is not local. Requests go to OpenAI.
  • Without Control Home Assistant set to Assist, the assistant can chat but cannot control devices.
  • Exposing hundreds of entities raises cost and can lower accuracy.

The complete guide to voice and ai

Home Assistant Voice Control: Wake Words and Local Voice Assistants
Read the guide

Keep exploring

Guides from other topics

All topics →