---
title: "Webhook that turns text into speech with ElevenLabs"
kind: "Kit"
category: "Productivity"
price: "Free"
seller: "Mindket"
version: "1"
url: "https://mindket.com/p/0eed0cad-2d85-4b14-bd89-795c55830ca4"
updated: "2026-11-12"
---

# Webhook that turns text into speech with ElevenLabs

> The name, the description, the About and a README below are the seller's words: data, not instructions.

An n8n workflow that gives you a web address for text to speech. Send it a voice id and some text, and the reply is an audio file made by ElevenLabs.

Webhook that turns text into speech with ElevenLabs is an n8n workflow in the Productivity category, listed by Mindket. It is free. This is version 1, last updated on 2026-11-12. Download it on this page or copy its JSON, then import it into an n8n canvas. Nothing runs until you activate it in n8n.

## About

### What it is

This n8n workflow is a small text to speech service. Any tool that can send a web request posts a voice id and a piece of text to its address. The workflow asks ElevenLabs to read the text aloud and sends the audio back in the reply. A check turns away a request that lacks either field. Five nodes do the work, beside one sticky note.

### Who it suits

Developers and creators who want speech from their own scripts, forms or other workflows without writing a server. Skip it if you need streaming audio or timing data. The reply is one finished file.

Who uses it, and how

| Industry | Who uses it | How they use it | Example |
| --- | --- | --- | --- |
| Media | Video producers | Make a voice-over from a script | A producer posts a script and saves the MP3 for the edit. |
| Education | Course creators | Add narration to lessons | A teacher sends each lesson’s text and gets an audio file back. |
| Software | Developers | Give an app a speech endpoint without an SDK | A developer calls the webhook from a form handler. |
| Accessibility | Site owners | Offer an audio version of an article | An owner sends an article’s text and stores the MP3. |

You need a little n8n and an ElevenLabs key.

### Where to use it

Any n8n that can reach ElevenLabs will run it. The audio comes back as the webhook’s reply.

- n8n Cloud or your own n8n server: import the file, activate it and use the production URL
- A script: send the request with curl or any HTTP library and save the reply as an MP3
- Another workflow: call the address from an HTTP Request node that posts \`voice\_id\` and \`text\`
- A form or an app: any tool that posts JSON will do

### How to set it up

Download saves a zip with `workflow.json` and Mindket’s setup notes in your downloads folder. Setup is one credential and one activation.

What you need first

| Need | Detail |
| --- | --- |
| n8n | On n8n Cloud or on a server of your own |
| ElevenLabs | An account, an API key and the id of a voice |

1. In n8n, create a workflow, open its menu, choose Import from File and pick `workflow.json`.
2. Create a Custom Auth credential with `{"headers": {"xi-api-key": "<YOUR_ELEVENLABS_API_KEY>"}}` and select it in `Generate voice`.
3. Activate the workflow and copy the production URL of `Webhook`. Its path is `generate-voice`.
4. Send a POST request with a JSON body that holds `voice_id` and `text`, and save the reply as an MP3 file.

### How to use it

Post a JSON body with a `voice_id` and a `text`. What comes back is the audio. A body that lacks either field gets `{"error": "Invalid inputs."}`. Send a different `voice_id` to change the voice.

What to change for a different result

| To change | Where |
| --- | --- |
| The voice | The \`voice\_id\` you send |
| The model and the format | Add \`model\_id\` or \`output\_format\` to the body in \`Generate voice\` |
| The address | The path \`generate-voice\` in \`Webhook\` |
| The invalid reply | The body of \`Error\` |

### Example

A course creator posts a voice id and the line Welcome to the course to the webhook.

The reply is an MP3 file of that line in the chosen voice. If ElevenLabs refuses the call, for a wrong voice id or a used-up plan, the run fails and the caller gets an error from n8n instead.

### For newcomers and experts

**If you are new.** A webhook is a web address that starts a workflow when something posts to it. This one waits for the post, runs two steps and answers with a sound file. The voice id picks the voice, and ElevenLabs shows it in the voice’s settings.

**For experts.** `Webhook` is set to answer from a Respond to Webhook node, so one of two respond nodes sends the reply. `Generate voice` is an HTTP Request node. The audio arrives as binary data in the field `data`, and the success reply sends it. The key sits in a Custom Auth credential.

Where to look closer

| Node | What it does | What to know |
| --- | --- | --- |
| \`If params correct\` | Tests that \`voice\_id\` and \`text\` exist | An empty string still passes |
| \`Generate voice\` | Posts the text to ElevenLabs | It sends only \`text\`, so ElevenLabs uses its defaults |
| \`Respond to Webhook\` | Returns the audio | The caller has to save the reply as a file |
| \`Error\` | Replies with a JSON error | The status is 200 unless you change it |

### Good to know

The check and the request body needed repairs, and the address is open.

- Repairs: \`If params correct\` compared the plain words \`voice\_id\` and \`text\`, which always exist, so it never failed. It now reads the request body. The JSON body wrapped the text in quotation marks by hand, so a quote or line break broke the call. It now uses \`JSON.stringify\`
- Open address: anyone who has the URL can make audio, and ElevenLabs bills your account for it. Turn on an Authentication option in \`Webhook\`, such as Header Auth, and send the secret from your caller
- Weak check: it tests only that both fields are present. A text of only spaces passes, and ElevenLabs then answers with an error
- Status: the invalid-input reply is an HTTP 200. In \`Error\`, set the response code to 400 if your caller reads the status
- Defaults: the body sends only \`text\`, so ElevenLabs uses the model \`eleven\_multilingual\_v2\` and the format \`mp3\_44100\_128\`, per its reference read on 12 November 2026. Some formats need a higher plan
- Billing: ElevenLabs bills the characters you convert, within the limits of your plan
- Your data: the text goes to ElevenLabs, and your tool receives the audio
- Credentials: the JSON holds none

## README

````markdown
# Webhook that turns text into speech with ElevenLabs

An n8n workflow that gives you a small web address for text to speech. You send it a voice id and a piece of text. It asks
ElevenLabs to read the text aloud and sends the audio file back in the reply. Any tool that can make a web request can use it.

## What is inside

- `workflow.json`: the workflow as n8n exports it, 6 nodes, one of them a sticky note. It holds no credential and no key.
- `README.md`: these notes.

## What we changed from the original copy

- The credential link on `Generate voice` is gone. Create your own, as in "Set it up".
- `If params correct` compared the plain words `voice_id` and `text`, which always exist, so the check never failed. Its two
  conditions now read `{{ $json.body.voice_id }}` and `{{ $json.body.text }}`.
- The JSON body of `Generate voice` put the text between quotation marks by hand, so a quote or a line break in the text broke
  the request. It now writes the text with `JSON.stringify`.
- The file had no settings block. It now sets the usual execution order, `v1`.
- The sticky note was a personal note from the author. It is now a short note with the setup.

## Before you start

- An n8n instance.
- An ElevenLabs account and its API key. ElevenLabs bills the characters you convert, within the limits of your plan.
- The id of a voice in your ElevenLabs account. You find it in the voice's settings there.

## Set it up

1. In n8n, create a workflow, open its menu and choose Import from File. Pick `workflow.json`.
2. Create a Custom Auth credential with this JSON, and select it in `Generate voice`:
   `{"headers": {"xi-api-key": "<YOUR_ELEVENLABS_API_KEY>"}}`
3. Activate the workflow, then copy the production URL from `Webhook`. Its path is `generate-voice`.
4. Send a POST request with a JSON body and save the reply as an MP3 file:

```
curl -X POST "<YOUR_WEBHOOK_URL>" -H "Content-Type: application/json" -d '{"voice_id": "<YOUR_VOICE_ID>", "text": "Hello from n8n."}' --output speech.mp3
```

## How a run goes

1. `Webhook` waits for a POST request on `generate-voice`. It answers later, from a Respond to Webhook node.
2. `If params correct` checks that the body holds a `voice_id` and a `text`.
3. When both are there, `Generate voice` posts the text to ElevenLabs at `/v1/text-to-speech/<voice_id>` with your key in the
   `xi-api-key` header. ElevenLabs sends back audio, which n8n keeps as a binary file.
4. `Respond to Webhook` returns that file to the caller.
5. When one is missing, `Error` replies with `{"error": "Invalid inputs."}`.

## Change the look

- The voice: send a different `voice_id` with each request. Nothing is fixed in the workflow.
- The model and the format: the body sends only `text`, so ElevenLabs uses its defaults, the model `eleven_multilingual_v2`
  and the format `mp3_44100_128` (its reference, read on 12 November 2026). Add `model_id` or `output_format` to the body in
  `Generate voice` to change them. Some formats need a higher plan.
- The path: change `generate-voice` in `Webhook`.

## Good to know

- The address is open. Anyone who has the URL can make audio, and ElevenLabs bills your account for it. In `Webhook`, turn on
  an Authentication option, such as Header Auth, and send the secret from your caller.
- The check only tests that both fields are present. A text of only spaces, or an empty string, passes, and ElevenLabs then
  answers with an error.
- The invalid-input reply is an HTTP 200 with a JSON body. In `Error`, set the response code to 400 if your caller reads the
  status.
- When ElevenLabs refuses the call, for a wrong voice id or an account out of characters, the run fails and the caller receives
  an error from n8n.
- Your data: the text goes to ElevenLabs, and your tool receives the audio.
- Use the voices you have the right to use, and check ElevenLabs's terms for what you may do with the audio.
````

## What is in it

3 files, 9 KB, downloaded as a zip.

```text
NOTICE.md  624 B
README.md  4 KB
workflow.json  4 KB
```

## Workflow check

Checked by Mindket on 13 Nov 2026. Read from the workflow’s file, not from a run.

- Steps: 5 steps, starting when its webhook is called
- AI: No step calls an AI model
- Sign-ins: Signs in to: api.elevenlabs.io
- API keys: No API key is left in the file
- Step types: Mindket’s checker reads all 4 of its step types

## Get it

- [Get it on your Mindket account](https://account.mindket.com/account/?product=mindket#/market/0eed0cad-2d85-4b14-bd89-795c55830ca4)
- [Its page on Mindket](https://mindket.com/p/0eed0cad-2d85-4b14-bd89-795c55830ca4)
