LiteLLM

The LiteLLM integrationIntegrations connect and integrate Home Assistant with your devices, services, and more. [Learn more] allows you to use a LiteLLM proxy as a conversation agent in Home Assistant.

LiteLLM exposes a single OpenAI-compatible API in front of a wide range of model providers, so you can use almost any model through one endpoint. This is similar to a service like OpenRouter, with the added benefit that you can run LiteLLM yourself if you prefer to keep everything under your own control. This integration lets you point Home Assistant at any LiteLLM proxy, whether it is a hosted instance or one you self-host.

Prerequisites

Before you add this integration, you need the following:

  • A LiteLLM proxy that Home Assistant can reach. This is the endpoint the integration connects to. You can use a hosted LiteLLM proxy or run one yourself.
  • At least one model configured on the proxy. The integration discovers the available models from the proxy during setup and creates a conversation agent for each one.
  • An API key, if your proxy requires authentication. This is used to authorize Home Assistant’s requests to the proxy. You can leave it empty if your proxy does not require one.

Configuration

To add the LiteLLM service to your Home Assistant instance, use this My button:

Manual configuration steps

If the above My button doesn’t work, you can also perform the following steps manually:

URL

The base URL of your LiteLLM proxy, including the host and port. The integration automatically appends the OpenAI /v1 path if it is missing.

API key

An optional LiteLLM API key or virtual key. Leave it empty if your proxy does not require authentication.

Adding a conversation agent

After the integration is set up, add a conversation agent for the model you want to use:

  1. Go to Settings > Devices & services and select your LiteLLM entry.
  2. Select Add conversation agent.
  3. Fill in the fields:
Model

The model to use for the conversation agent. The list is discovered from your LiteLLM proxy.

Instructions

Instruct how the LLM should respond. This field supports templates.

Control Home Assistant

Select which tools the agent can use to interact with your devices and entities. Leave empty if you do not want the agent to control Home Assistant.

To change the model, instructions, or tools later, select the conversation agent and choose Reconfigure conversation agent.

Supported functionality

This integration provides a conversation agent for each model you add. You can use it in Assist like any other conversation agent.

When you grant the agent control of Home Assistant, it can call the configured tools to interact with your devices and entities. To choose which devices and entities the agent can access, see exposing entities to Assist.

Removing the integration

This integration follows standard integration removal, no extra steps are required.

To remove an integration instance from Home Assistant

  1. Go to Settings > Devices & services and select the integration card.
  2. From the list of devices, select the integration instance you want to remove.
  3. Next to the entry, select the three dots menu. Then, select Delete.