ElevenLabs Music integration
Powered by ElevenLabs technology, this API generates original music tracks from text descriptions.
Key capabilities
- Text-guided generation: Describe any music style to generate (e.g., “Upbeat jazz with piano and drums”, “Cinematic orchestral soundtrack”)
- Customizable duration: Generate tracks from 10 seconds to 240 seconds (4 minutes)
- High-quality output: Professional-grade MP3 audio files suitable for production use
- Genre flexibility: Support for any music genre, style, or mood
- Async processing: Webhook notifications or polling for task completion
Use cases
- Video production: Create background music for videos and presentations
- Game development: Generate custom soundtracks for games and apps
- Content creation: Produce unique music for podcasts, streams, and social media
- Advertising: Create original jingles and background tracks for ads
- Film production: Generate temp tracks or production music for films
Generate music with ElevenLabs
Submit a text description of the music you want to create along with the desired duration. The service returns a task ID for async polling or webhook notification.Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
prompt | string | Yes | - | Text description of the music to generate (e.g., “Upbeat jazz with piano”, “Melancholic piano ballad”) |
music_length_seconds | integer | Yes | - | Duration of the generated track in seconds (10-240) |
webhook_url | string | No | - | HTTPS URL for task completion notification |
Prompt tips
For best results, include details about:- Genre: jazz, electronic, classical, rock, ambient, etc.
- Mood: upbeat, melancholic, energetic, peaceful, dramatic
- Instruments: piano, guitar, drums, synthesizer, strings, etc.
- Tempo: slow, moderate, fast-paced, groove
- “A Blues guitar solo with emotional bends and slides”
- “Upbeat electronic dance music with synthesizers and heavy bass”
- “Peaceful ambient piano with gentle strings in the background”
- “Cinematic orchestral piece building to an epic climax”
- “Modern corporate background music with light piano and subtle electronic elements”
Frequently Asked Questions
What is ElevenLabs Music and how does it work?
What is ElevenLabs Music and how does it work?
ElevenLabs Music is an AI-powered text-to-music API. You submit a text description of the music you want (genre, mood, instruments, tempo) along with the desired duration, receive a task ID immediately, then poll for results or receive a webhook notification. The output is a high-quality MP3 audio file.
What music duration range is supported?
What music duration range is supported?
You can generate music tracks from 10 seconds (minimum) to 240 seconds / 4 minutes (maximum). The duration is specified in the
music_length_seconds parameter.How do I write effective music prompts?
How do I write effective music prompts?
Be specific about genre, mood, instruments, and tempo. Good examples: “Upbeat jazz with piano and brushed drums”, “Melancholic acoustic guitar ballad”, “Epic orchestral soundtrack with building tension”. Avoid vague prompts like just “music” or “song”.
What is the output format?
What is the output format?
ElevenLabs Music outputs MP3 audio files at professional quality. The generated audio is delivered via a URL that remains accessible for download after task completion.
How long does generation take?
How long does generation take?
Generation typically takes 30-90 seconds depending on track duration. Shorter tracks (10-30 seconds) usually complete in under a minute, while maximum-length tracks (4 minutes) may take 1-2 minutes. For production workflows, use webhooks for efficient notification.
What are the rate limits for ElevenLabs Music?
What are the rate limits for ElevenLabs Music?
Rate limits vary by subscription tier. See Rate Limits for current limits.
How much does ElevenLabs Music cost?
How much does ElevenLabs Music cost?
See the Pricing page for current rates and subscription options.
Best practices
- Prompt specificity: Use detailed descriptions for better generation accuracy
- Duration planning: Consider your use case when selecting track length
- Genre mixing: Combine styles for unique results (e.g., “jazz-influenced electronic”)
- Production integration: Use webhooks instead of polling for scalable applications
- Error handling: Implement retry logic with exponential backoff for 503 errors
Related APIs
- Sound Effects: Generate sound effects from text descriptions
- Audio Isolation: Isolate specific sounds from audio files
- Lip Sync: Synchronize lip movements to audio tracks
- OmniHuman 1.5: Generate human animations driven by audio