Langsung ke konten
POST AI agent ready /v1/age/estimate

Age Estimation API - Predict Age from First Name

Predicts the most likely age for a given first name using a statistical model trained on public census and demographic data. Optionally filter by country to get region-specific estimates. Returns the predicted age and the sample count used for the prediction.

Parameters

stringrequired

First name to estimate age for.

string

ISO 3166-1 alpha-2 country code to narrow the estimate to a specific country.

Code examples

curl -X POST https://api.botoi.com/v1/age/estimate \
  -H "Content-Type: application/json" \
  -d '{"name":"Michael","country_id":"US"}'

When to use this API

Demographic segmentation for marketing

Estimate the age distribution of your user base from first names in your signup database. Segment users into age groups (18-25, 26-35, 36-50, 50+) and tailor email campaigns, product recommendations, and ad creatives to each segment.

Form pre-filling and UX optimization

Use the estimated age to pre-select relevant options in onboarding forms. For a financial services app, if the predicted age is 60+, default to retirement planning content. For predicted ages 20-30, highlight student loan or first-home-buyer resources.

Data enrichment for CRM records

Enrich CRM contacts that have a first name but no age or birth date. Add an estimated age field that sales teams can use for more personalized outreach. Flag low-confidence predictions (small count values) for manual review.

Frequently asked questions

How accurate is the age prediction?
Accuracy depends on the name and country. Common names with large sample counts (100k+) typically predict within 5-8 years of the actual average. Rare names or names popular across multiple generations have wider variance. The count field indicates confidence; higher counts mean more reliable predictions.
What does the count field represent?
The count is the number of data samples used to calculate the predicted age. A count of 233,482 means the prediction is based on over 233k records with that name. Higher counts generally produce more reliable estimates.
Does the country_id parameter change the result?
Yes. Name popularity and age distributions vary by country. "Michael" is associated with an older demographic in the US but may skew younger in other countries. Providing a country_id gives a more targeted estimate.
Can I estimate age for any language or script?
The model performs best with Latin-script names common in Western countries. Names in non-Latin scripts (Chinese, Arabic, Cyrillic) may have lower sample counts and less reliable predictions.
Is the name case-sensitive?
No. Names are normalized to lowercase before processing. "Michael", "michael", and "MICHAEL" all return the same result.

Get your API key

Free tier includes 5 requests per minute with no credit card required. Upgrade for higher limits.