Find the queries people type with a Google Autocomplete API
A Google Autocomplete API returns the queries people start typing, the most direct record of how a market phrases a problem. SEO teams plan content with it, product teams name features with it, and agents expand a vague prompt into precise searches. The Search API returns suggestions, related searches and People Also Ask questions as JSON.
Keyword lists come from guesses, or from a tool that guesses for you
Content that ranks answers the question people actually type. A brainstorm produces the phrasing a team uses internally, which rarely matches the long-tail queries buyers enter, and those long-tail variants are where a new page has a chance.
Typing seeds into a search box and copying the dropdown works for five queries, not five hundred. Keyword suites solve scale with their own databases and a seat price, and calling a suggest endpoint yourself means handling blocking and parsing for a result that is only a list of strings.
type: autocomplete returns suggestions as value strings, and it is lightweight and fast. The default web search adds relatedSearches and peopleAlsoAsk to the results page, turning one seed into follow-up queries and real questions. location geo-targets both by country, so the ideas match the market you write for.
How to get keyword suggestions from the Google Autocomplete API
Expand a seed with autocomplete, add a letter to reach the long tail, then pull the questions from the results page. The autocomplete guide shows the result shape.
import createClient from 'microlink.io'
const microlink = createClient({
apiKey: process.env.MICROLINK_API_KEY
})
const page = await microlink.search('headless browser', {
type: 'autocomplete',
location: 'us'
})
const ideas = page.results.map(({ value }) => value)Each suggestion is a value string. Autocomplete results have no url, so there is nothing to expand: they are inputs for the next query.
import createClient from 'microlink.io'
const microlink = createClient({
apiKey: process.env.MICROLINK_API_KEY
})
const seed = 'headless browser'
const letters = 'abcdefghijklmnopqrstuvwxyz'.split('')
const pages = await Promise.all(
letters.map(letter =>
microlink.search(seed + ' ' + letter, {
type: 'autocomplete',
location: 'us'
})
)
)
const longTail = Array.from(
new Set(pages.flatMap(({ results }) => results.map(({ value }) => value)))
)Twenty-six requests collect the suggestions for every next letter, deduplicated with a Set. Save it for the seeds that matter, not every idea on the list.
import createClient from 'microlink.io'
const microlink = createClient({
apiKey: process.env.MICROLINK_API_KEY
})
const serp = await microlink.search('headless browser api', {
location: 'us'
})
const questions = (serp.peopleAlsoAsk || []).map(({ question }) => question)
const related = (serp.relatedSearches || []).map(({ query }) => query)The default search type returns peopleAlsoAsk and relatedSearches next to the results when Google shows them. Questions become headings and FAQ entries; related searches become the next seeds.
- type 'autocomplete' returns suggestions as value strings. Results cannot be expanded.
- location Two-letter country code. There is no language option, only country.
- relatedSearches Follow-up queries from the web results page, as objects with a query field.
- peopleAlsoAsk Related questions with question, snippet, title and link, when Google shows them.
None of these surfaces returns search volume, cost per click or keyword difficulty. Use them to discover phrasing and questions, then size the shortlist with the metrics source you already trust. The query expansion pattern shows autocomplete feeding heavier searches.
Why autocomplete beats a brainstorm for keyword research
Suggestions are what people type, in the words they type it. That makes them the right raw material for a keyword list.
Check where you already rank for the phrases you find with rank tracking by country.
Want the whole results page as text for a content brief? Get the SERP as Markdown from the same query.
When not to: autocomplete does not tell you how many people search a phrase or how hard it is to rank for it. If you prioritize by volume or difficulty, pair these ideas with a keyword metrics source. Grounding an assistant in live results instead? See live search for LLM answers.
FAQ
How do I use the Google Autocomplete API for keyword research?
Does the keyword suggestions API return search volume?
Can I get People Also Ask questions through the Search API?
How many requests does autocomplete keyword research use?
Is this Google Suggest API an official Google product?
Solve the next problem with the same API
Google rank tracking by country
Google results page as Markdown or HTML
Live search to ground LLM answers
Local business leads from Google Maps
LLM context from any URL
Custom fields alongside metadata
Ready to find what people search?
Autocomplete suggestions, related searches and questions as JSON, per country. Get a Pro key and expand your first seed today.