Skip to main content
Table of contents

Vehicle Enquiry Service API

Introduction

The DVLA Vehicle Enquiry API is a RESTful service that provides vehicle details of a specified vehicle. It uses the vehicle registration number as input to search and provide details of the vehicle. The response data is provided in JSON format. The functional specification of this format is detailed in the OpenAPI 3.0 documentation below:

For more details visit the OpenAPI specification page.
You can also view the OpenAPI specification in JSON format.

Register For VES API

If you want to register for this API, please click the button below:

Apply

VES API Usage

Requests

To call the API, make a HTTP POST request to the following URL:

https://driver-vehicle-licensing.api.gov.uk/vehicle-enquiry/v1/vehicles

and include the following in the request body:

{ "registrationNumber": "TE57VRN" }

You must also include a mandatory x-api-key header with each request you send. This must contain the API key which you have been issued with.

For example, using cURL, a request can be made as follows:

curl -L -X POST 'https://driver-vehicle-licensing.api.gov.uk/vehicle-enquiry/v1/vehicles' \
-H 'x-api-key: REPLACE WITH YOUR API KEY' \
-H 'Content-Type: application/json' \
-d '{"registrationNumber": "TE57VRN"}'

OWASP security guidelines dictate that sensitive information should not be included in URLs. This reduces the risk of sensitive information being unnecessarily recorded in Web Server logs. The vehicle registration number is deemed sensitive information in accordance with the Information Commissioner’s Office (ICO), so is passed in the body as a POST request.

Responses

A sample JSON response is below:

{
  "artEndDate": "2025-02-28",
  "co2Emissions" : 135
  "colour" : "BLUE"
  "engineCapacity": 2494,
  "fuelType" : "PETROL"
  "make" : "ROVER"
  "markedForExport" : false
  "monthOfFirstRegistration" : "2004-12"
  "motStatus" : "No details held by DVLA"
  "registrationNumber" : "ABC1234"
  "revenueWeight" : 1640
  "taxDueDate" : "2007-01-01"
  "taxStatus" : "Untaxed"
  "typeApproval" : "N1"
  "wheelplan" : "NON STANDARD"
  "yearOfManufacture" : 2004
  "euroStatus": "EURO 6 AD"
  "realDrivingEmissions": "1"
  "dateOfLastV5CIssued": "2016-12-25"
}

Error Responses

The functional OpenAPI specification referenced above lists the error format and values returned from the enquiry service itself.

In addition to this, the common errors section gives errors that may be thrown by the surrounding framework.

Code Examples

A list of code examples can be found here.

Postman Collection

A postman collection for the VES API can be downloaded here.

Test Environment

Optionally, access to a test environment can be provided which will allow you to test your integration using a number of predefined vehicle registration numbers (VRN), including error responses.

Example - Using the VRN ‘ER19BAD’ results in a 400 Bad Request

Request
To call the test API, make a HTTP POST request to the following URL:

https://uat.driver-vehicle-licensing.api.gov.uk/vehicle-enquiry/v1/vehicles

and include the following in the request body:

{ "registrationNumber": "ER19BAD" }

You must also include a mandatory x-api-key header with each request you send. This must contain the test environment API key which you have been issued with.

For example, using cURL, a request can be made as follows:

curl -L -X POST 'https://uat.driver-vehicle-licensing.api.gov.uk/vehicle-enquiry/v1/vehicles' \
-H 'x-api-key: REPLACE WITH YOUR API KEY' \
-H 'Content-Type: application/json' \
-d '{"registrationNumber": "ER19BAD"}'

Response

{
  "errors": [
    {
      "status": 400,
      "code": "ENQ103",
      "title": "Bad Request",
      "detail": "Invalid format for field - vehicle registration number"
    }
  ]
}

A full list of test VRNs can be found here.

Usage Plans and Throttling Limits

We have introduced limits on API usage rates in terms of requests per second. This applies to both individual clients and collective usage for all clients.

  1. A client’s limit is set based on the usage plan that the client is subscribed to
  2. As clients access the API at the same time, there is an overall limit on how many requests are allowed per second in order to protect the service

These two scenarios will return an HTTP status code of 429 as specified in the common errors section.