Datamuse API
Word-finding query engine — rhymes, synonyms, related words and more.
What it does
Datamuse is a word-finding API for writers and word games. One endpoint, many constraints: words that rhyme with, sound like, are spelled like, mean like, are synonyms/antonyms of, or are commonly associated with a given word or phrase — combinable, with optional vocabulary and topic hints.
Base URL
Authentication
None. /words with constraint parameters (rel_rhy, sl, sp, ml, rel_syn, rel_trg, lc/rc for context). /sug is a prefix autocomplete endpoint.
Code examples
curl -s "https://api.datamuse.com/words?rel_rhy=mountain&max=5" curl -s "https://api.datamuse.com/words?ml=ringing+in+the+ears" # tinnitus curl -s "https://api.datamuse.com/words?sp=t??k" # task, talk, tick...
import requests
r = requests.get("https://api.datamuse.com/words", params={
"ml": "ocean", "topics": "weather", "max": 10}, timeout=10)
print([w["word"] for w in r.json()])Rate limits & quotas
Free for up to roughly 100,000 requests/day without prior arrangement; heavier or commercial use should contact the author. Each call returns at most 1,000 results (max parameter). Responses are a flat array sorted by a relevance score.
Key response fields
| [].word | The suggested word or phrase |
| [].score | Relevance/frequency score (higher = better match); not a probability |
| [].tags[] | Optional: part of speech (n, v, adj), syn, pronunciation (pron), frequency (f) |
| [].numSyllables | With md=s metadata flag |
Common errors
| [] empty | No words satisfy the constraints — loosen them (e.g. drop topics). |
| 400 | Conflicting or malformed parameters. |
| (scores aren't comparable across queries) | Use score only to rank within one response. |
When to use it (and alternatives)
Ideal for rhyme and thesaurus tools, crossword and Scrabble helpers, autocomplete with semantic hints, and constrained-writing games. For full dictionary definitions use the Free Dictionary API; for quotes, Quotable.
FAQ
How do I get synonyms?
?rel_syn=happy for strict synonyms, or ?ml=happy (‘means like’) for a broader, usually more useful set of related words.
What does the sp parameter do?
‘Spelled like’ with wildcards: ? matches one letter, * matches any number. sp=c*t → cat, coat, carrot… Great for crosswords.
Can I combine constraints?
Yes — e.g. ?ml=beach&sp=s* for beach-related words starting with s. Adding lc/rc (left/right context word) improves phrase-aware suggestions.
New to APIs?
Short guides for working with this API — and any other.