gov.uk APIwww.gov.uk ↗
Check UK visa requirements by nationality and travel purpose. Returns visa_needed boolean, outcome title, and full GOV.UK guidance text for any country.
No input parameters required.
curl -X GET 'https://api.parse.bot/scraper/4d69f77c-7ed7-465b-9bc8-901cc6b8c1ae/list_nationalities' \ -H 'X-API-Key: $PARSE_API_KEY'
List all supported nationalities for the UK visa checker. Returns the full set of nationality codes and display names accepted by check_visa. Each entry has a 'code' (the slug to pass as the nationality parameter) and a 'name' (the human-readable country name). The list is sourced from the GOV.UK visa checker dropdown and contains 221 entries covering all recognized countries and territories.
No input parameters required.
{
"type": "object",
"fields": {
"total": "integer count of nationalities",
"nationalities": "array of nationality objects each with code (string) and name (string)"
},
"sample": {
"data": {
"total": 221,
"nationalities": [
{
"code": "afghanistan",
"name": "Afghanistan"
},
{
"code": "india",
"name": "India"
},
{
"code": "usa",
"name": "United States of America"
}
]
},
"status": "success"
}
}About the gov.uk API
The GOV.UK Visa Checker API exposes 2 endpoints to determine UK entry requirements for any nationality and travel purpose. Call list_nationalities to retrieve the full set of accepted nationality codes, then pass a code and purpose to check_visa to get a structured result including a visa_needed boolean, an outcome_title, and the complete guidance text from the official GOV.UK visa checker tool.
Endpoints and Data Returned
list_nationalities takes no inputs and returns a total count alongside a nationalities array. Each element in the array carries a code — the slug you pass as the nationality parameter downstream — and a human-readable name. Use this endpoint to build or validate a nationality picker before calling the visa check.
check_visa accepts two required parameters: nationality (a code from list_nationalities, e.g. india, usa, china) and purpose (the reason for visiting the UK). It returns three fields: visa_needed (a boolean, or null when the outcome cannot be determined definitively), outcome_title (a short summary string), and details (the full guidance text as presented by GOV.UK, which may include application instructions, document requirements, and eligibility conditions).
Coverage and Behavior
The check_visa endpoint mirrors the multi-step GOV.UK visa checker flow. For journeys where the outcome depends on additional sub-questions, the response may return null for visa_needed along with details that explain the indeterminate result. The outcome_title will still indicate the direction of the guidance in those cases. Nationality codes are not ISO 3166 alpha-2; they are GOV.UK slugs, so using list_nationalities first is the reliable way to confirm accepted values.
- Embed a UK visa requirement lookup in a travel booking flow using nationality codes from
list_nationalities - Build a pre-trip checklist app that flags whether a user's nationality requires a UK visa based on
visa_needed - Display the full
detailsguidance text to users so they know what documents to prepare before applying - Automate compliance checks for HR teams onboarding international employees who will travel to the UK
- Populate a country-selection dropdown with all valid
codeandnamepairs for a visa-screening form - Generate alerts when the
outcome_titleindicates a visa is required for a specific nationality–purpose combination
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 250 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does GOV.UK offer an official developer API for the visa checker?+
What does `visa_needed` return when the outcome isn't clear-cut?+
visa_needed returns null when the GOV.UK flow reaches a result that cannot be expressed as a simple yes/no — for example, when the answer depends on the traveller's specific circumstances. In those cases, outcome_title will still reflect the direction of the outcome, and details will contain the full explanatory guidance text.Are transit or airside transit visa requirements covered?+
purpose values you pass. The API reflects the outcomes of the GOV.UK tool for the purposes it supports; coverage of transit-specific scenarios is tied to whether GOV.UK's own checker addresses them for a given nationality. You can fork this API on Parse and revise it to add dedicated handling for transit-purpose flows if your use case requires it.Does the API return application fees, processing times, or visa category names?+
visa_needed, outcome_title, and details (guidance text). Fee and processing-time data are not part of the structured output. You can fork this API on Parse and revise it to extract those details from the details text or add a supplementary endpoint.How do nationality codes work — can I use standard ISO country codes?+
nationality parameter uses GOV.UK-specific slugs (e.g. india, usa, china, france), not ISO 3166 alpha-2 codes. Always call list_nationalities first to retrieve the exact code values the check_visa endpoint accepts.