π€― LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.
TypeScript agentagent-collaborationagent-harnessloop-engineeringmcppersonal-assistantproactive-agentskillssuper-agenttask-management
---
title: Using ElevenLabs API Key in LobeHub
description: >-
Configure an ElevenLabs API key in LobeHub and generate lifelike speech with Eleven v4, Eleven Multilingual v2, and Eleven Flash v2.5.
tags:
- ElevenLabs
- Text to Speech
- TTS
- API Key
---
# Using ElevenLabs in LobeHub
[ElevenLabs](https://elevenlabs.io) is an AI audio company. Its text-to-speech models generate expressive speech in 90+ languages from a large voice library. In LobeHub, ElevenLabs is a text-to-speech provider only: it has no chat models.
<Steps>
### Step 1: Obtain your ElevenLabs API key
- Sign up or sign in at [ElevenLabs](https://elevenlabs.io).
- Open [API Keys](https://elevenlabs.io/app/settings/api-keys) and create a key.
- Copy the key and store it securely.
### Step 2: Configure ElevenLabs in LobeHub
- Open **App Settings β AI Providers** and select **ElevenLabs** (type `Eleven` in the provider search box to find it).
- Paste your key into **API Key**. Changes are saved automatically, and the key is encrypted with AES-GCM before it is stored.
- Turn on the switch next to the provider name.
- Optional: if your ElevenLabs workspace uses a data-residency endpoint, enter it in **API Proxy URL** (for example `https://api.eu.residency.elevenlabs.io`). Leave it empty to use `https://api.elevenlabs.io`.
### Step 3: Choose models
The **Model List** shows the ElevenLabs speech models under the **TTS** tab. Eleven v4, Eleven Multilingual v2, and Eleven Flash v2.5 are enabled by default; Eleven v3, Eleven Flash v2, and Eleven Turbo v2.5 can be turned on in the same list.
ElevenLabs has no chat model, so the provider page shows no **Check** button. Verify the key by generating speech as described below.
<Callout type={'warning'}>
ElevenLabs bills each synthesized character. Review the [ElevenLabs API pricing](https://elevenlabs.io/pricing/api) before generating large amounts of audio.
</Callout>
</Steps>
## Generate speech
Speech synthesis runs through the LobeHub text-to-speech API, which the LobeHub CLI (`lh`) and the OpenAI-compatible `POST /api/v1/audio/speech` endpoint both use:
```bash
lh generate tts "Hello from LobeHub" -m elevenlabs/eleven_v4 -o hello.mp3
```
- **Voice** β when no voice is given, the default voice Roger is used, which also works with free-tier keys. Pass `--voice <voice id>` to use another voice from the built-in list or from your own ElevenLabs voice library.
<Callout type={'warning'}>
Apart from the default Roger, the built-in voices come from the ElevenLabs Voice Library, which **free-tier API keys cannot use through the API**. On the free plan, keep the default or pass a voice you own (for example one created with Voice Design or Instant Voice Cloning) with `--voice <voice id>`, or upgrade to a paid plan. Roger is one of the ElevenLabs Default voices, which only accounts created before March 2026 can use, until ElevenLabs retires them on 2026-12-31. When Roger is not available to your account, LobeHub picks a voice from your account instead (your own voices first, then premade ones); this needs the `voices_read` permission on the key. If no usable voice is found, pass one with `--voice`.
</Callout>
- **Length** β each request is limited to 4,096 characters, because the audio is returned in a single response. Split longer text into several requests.
- **Format** β `mp3` (default) or `opus`.
- **Speed** β Eleven Multilingual v2 and the Flash and Turbo models accept a speed from `0.7` to `1.2`. Eleven v3 and v4 do not accept a speed setting.
## Troubleshooting
**"ElevenLabs API Key is incorrect or empty, please check your ElevenLabs API Key and try again."** β No key was found, or ElevenLabs rejected the key. Enter a valid key in **App Settings β AI Providers β ElevenLabs**, or ask the administrator to set `ELEVENLABS_API_KEY` on the server. When ElevenLabs rejected the key, its own message follows in parentheses, for example `ElevenLabs API error (401): Invalid API key`.
**"Free-tier ElevenLabs keys cannot use Voice Library voicesβ¦"** β Your key is on the free plan and the voice comes from the Voice Library. See the voice note above.
**Quota or rate-limit errors** β Your ElevenLabs plan has run out of characters or reached its concurrency limit. Check usage in the ElevenLabs dashboard.
For self-hosted deployments, see `ELEVENLABS_API_KEY` in the [model provider environment variables](/docs/self-hosting/environment-variables/model-provider#elevenlabs).