Introduction
The Better Lyrics API serves syllable-synced lyrics for any song, for free. It powers the Better Lyrics browser extension, and you can use it in your own apps too.
Base URL
Send every request to:
https://api.betterlyrics.org Quick start
Fetch lyrics for a song with a single GET request:
curl "https://api.betterlyrics.org/getLyrics?s=E85&a=Don%20Toliver&al=OCTANE&d=154"const res = await fetch("https://api.betterlyrics.org/getLyrics?s=E85&a=Don%20Toliver&al=OCTANE&d=154");
const { ttml } = await res.json();import requests
res = requests.get("https://api.betterlyrics.org/getLyrics?s=E85&a=Don%20Toliver&al=OCTANE&d=154")
ttml = res.json()["ttml"]package main
import (
"fmt"
"io"
"net/http"
)
func main() {
res, err := http.Get("https://api.betterlyrics.org/getLyrics?s=E85&a=Don%20Toliver&al=OCTANE&d=154")
if err != nil {
panic(err)
}
defer res.Body.Close()
body, err := io.ReadAll(res.Body)
if err != nil {
panic(err)
}
fmt.Println(string(body))
} Parameters
| Parameter | Required | Description |
|---|---|---|
s, song, or songName | Always send | The song title |
a, artist, or artistName | Always send | The artist name |
al, album, or albumName | Always send | The album name |
d or duration | Always send | Track duration in whole seconds |
The API rejects a request (422) only when both song and artist are missing. Send all four
anyway: the cache key includes album and duration, so a request without them often misses the cached
entry and, without an API key, returns 401.
Response
A successful response contains TTML (Timed Text Markup Language) with syllable-level timing:
{
"ttml": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>..."
} Key features
- Free to use. Cached responses need no API key, and most use cases have no usage limits
- Syllable-level sync, with a start and end time for every syllable, for karaoke-style display
- Several providers: TTML (default), Kugou and QQ, each suited to different uses
- Heavy caching, so cache hits are free and need no API key
- Two-tier rate limiting that keeps serving cached responses under load, even to rate-limited clients
- A circuit breaker that protects the API from upstream failures
Attribution
If your project uses this API, we'd appreciate a link to Better Lyrics. It helps other people find the project and keeps development going.
Next steps
- Authentication: API keys and when you need one
- Rate limiting: how the two tiers work
- Response format: parse and use the TTML response
- Playground: try the API in your browser