There is an update to the GOV.UK Prototype kit which may affect how your prototype works if you are not using the latest version. Contact #team-plat-ui on HMRC Slack (open in app) if you need more information or support.

Unique Taxpayer Reference

experimental

This is currently experimental because more research is needed.

This is currently experimental because more research is needed.

This pattern lets the user enter a Unique Taxpayer Reference (UTR). Do not call it a ‘Unique Taxpayer Reference number’.

When to use

Use this pattern when the user must enter a UTR to use a service.

If there is a good reason for asking for a UTR but the user does not have to enter one, make it optional.

When not to use

If there is no good reason for asking for a UTR and the user does not have to enter one to use the service, do not ask for one.

How it works

You can ask for the UTR as the main heading or <h1> of the screen. It may be a question or statement.

            <div class="govuk-form-group">
  <h1 class="govuk-label-wrapper"><label class="govuk-label govuk-label--xl" for="utr">
      What is your Self Assessment Unique Taxpayer Reference?
    </label>

  </h1>
  <span id="utr-hint" class="govuk-hint">
    This is 10 numbers, for example 1234567890. It will be on tax returns and other letters about Self Assessment. It may be called ‘reference’, ‘UTR’ or ‘official use’. You can <a class="govuk-link" href="https://www.gov.uk/find-lost-utr-number">find a lost UTR number</a>.
  </span>
  <input class="govuk-input govuk-input--width-10" id="utr" name="utr" type="text" aria-describedby="utr-hint">
</div>

<button class="govuk-button" data-module="govuk-button">
  Continue
</button>
          
              {% from "govuk/components/input/macro.njk" import govukInput %}
{% from "govuk/components/button/macro.njk" import govukButton %}

{{
  govukInput({
    label: {
      text: "What is your Self Assessment Unique Taxpayer Reference?",
      isPageHeading: true,
      classes: "govuk-label--xl"
    },
    hint: {
      html: 'This is 10 numbers, for example 1234567890. It will be on tax returns and other letters about Self Assessment. It may be called ‘reference’, ‘UTR’ or ‘official use’. You can <a class="govuk-link" href="https://www.gov.uk/find-lost-utr-number">find a lost UTR number</a>.'
    },
    id: "utr",
    name: "utr",
    classes: "govuk-input--width-10"
  })
}}

{{ govukButton({
  text: "Continue"
}) }}
            
            <div class="govuk-form-group">
  <h1 class="govuk-label-wrapper"><label class="govuk-label govuk-label--xl" for="utr">
      What is your Corporation Tax Unique Taxpayer Reference?
    </label>

  </h1>
  <span id="utr-hint" class="govuk-hint">
    This is 10 numbers, for example 1234567890. It will be on tax returns and other letters about Corporation Tax. It may be called ‘reference’, ‘UTR’ or ‘official use’. You can <a class="govuk-link" href="https://www.gov.uk/find-lost-utr-number">find a lost UTR number</a>.
  </span>
  <input class="govuk-input govuk-input--width-10" id="utr" name="utr" type="text" aria-describedby="utr-hint">
</div>

<button class="govuk-button" data-module="govuk-button">
  Continue
</button>
          
              {% from "govuk/components/input/macro.njk" import govukInput %}
{% from "govuk/components/button/macro.njk" import govukButton %}

{{
  govukInput({
    label: {
      text: "What is your Corporation Tax Unique Taxpayer Reference?",
      isPageHeading: true,
      classes: "govuk-label--xl"
    },
    hint: {
      html: 'This is 10 numbers, for example 1234567890. It will be on tax returns and other letters about Corporation Tax. It may be called ‘reference’, ‘UTR’ or ‘official use’. You can <a class="govuk-link" href="https://www.gov.uk/find-lost-utr-number">find a lost UTR number</a>.'
    },
    id: "utr",
    name: "utr",
    classes: "govuk-input--width-10"
  })
}}

{{ govukButton({
  text: "Continue"
}) }}
            

Or you can ask for the UTR as a normal form label, separate from the <h1>.

            <div class="govuk-form-group">
  <label class="govuk-label" for="utr">
    Self Assessment Unique Taxpayer Reference
  </label>
  <span id="utr-hint" class="govuk-hint">
    This is 10 numbers, for example 1234567890. It will be on tax returns and other letters about Self Assessment. It may be called ‘reference’, ‘UTR’ or ‘official use’. You can <a class="govuk-link" href="https://www.gov.uk/find-lost-utr-number">find a lost UTR number</a>.
  </span>
  <input class="govuk-input govuk-input--width-10" id="utr" name="utr" type="text" aria-describedby="utr-hint">
</div>
          
              {% from "govuk/components/input/macro.njk" import govukInput %}

{{
  govukInput({
    label: {
      text: "Self Assessment Unique Taxpayer Reference"
    },
    hint: {
      html: 'This is 10 numbers, for example 1234567890. It will be on tax returns and other letters about Self Assessment. It may be called ‘reference’, ‘UTR’ or ‘official use’. You can <a class="govuk-link" href="https://www.gov.uk/find-lost-utr-number">find a lost UTR number</a>.'
    },
    id: "utr",
    name: "utr",
    classes: "govuk-input--width-10"
  })
}}
            

Use a single text input and allow the user to enter:

  • 10 numbers, with or without spaces
  • 13 numbers, with or without spaces
  • 10 or 13 numbers that start or end with a k, for example k1234567890123 and 1234567890k

Remove spaces, characters and extra numbers before validating.

Provide help

Always provide help in the form of a label, normal content or hint text that is as clear as possible. This may include:

  • a short explanation of what a UTR is
  • where they can find it
  • what it looks like
  • an example – if you show an example, always use ‘1234567890’

You can use an image that shows where it is on documents and letters. You could also provide a link to Find a lost UTR number.

Do not use the details component to hide any help. Research shows users may:

  • not know what a UTR is
  • need help to know what a UTR looks like

Ask the user about the type of business earlier in the journey and use appropriate content. For example, if the business is a sole trader, tell the user they can find their UTR on letters about Self Assessment. If the business if a limited company, tell the user they can find it on letters about Corporation Tax.

Error messages

Error messages should be styled like this:

            <div class="govuk-form-group govuk-form-group--error">
  <label class="govuk-label" for="utr">
    Corporation Tax Unique Taxpayer Reference
  </label>
  <span id="utr-hint" class="govuk-hint">
    This is 10 numbers, for example 1234567890. It will be on tax returns and other letters about Corporation Tax. It may be called ‘reference’, ‘UTR’ or ‘official use’. You can <a class="govuk-link" href="https://www.gov.uk/find-lost-utr-number">find a lost UTR number</a>.
  </span>
  <span id="utr-error" class="govuk-error-message">
    <span class="govuk-visually-hidden">Error:</span> Enter your Corporation Tax Unique Taxpayer Reference
  </span>
  <input class="govuk-input govuk-input--width-10 govuk-input--error" id="utr" name="utr" type="text" aria-describedby="utr-hint utr-error">
</div>
          
              {% from "govuk/components/input/macro.njk" import govukInput %}

{{
  govukInput({
    label: {
      text: 'Corporation Tax Unique Taxpayer Reference'
    },
    hint: {
      html: 'This is 10 numbers, for example 1234567890. It will be on tax returns and other letters about Corporation Tax. It may be called ‘reference’, ‘UTR’ or ‘official use’. You can <a class="govuk-link" href="https://www.gov.uk/find-lost-utr-number">find a lost UTR number</a>.'
    },
    errorMessage: {
      text: 'Enter your Corporation Tax Unique Taxpayer Reference'
    },
    id: 'utr',
    name: 'utr',
    classes: 'govuk-input--width-10'
  })
}}
            

Make sure errors follow the guidance about error messages in the GOV.UK Design System and have specific error messages for specific error states.

If the UTR is empty

Say ‘Enter [whatever it is]’.
For example, ‘Enter your Self Assessment Unique Taxpayer Reference’.

If the UTR is in the wrong format

Say ‘Enter [whatever it is] in the correct format’.
For example, ‘Enter your partnership’s Self Assessment Unique Taxpayer Reference in the correct format’.

Research

Research has shown that users often expect this kind of information to be pre-populated, especially when they have signed in. Research has also shown users:

  • may not know what a UTR is
  • need help to know what their UTR looks like
  • need a specific error message so they know what went wrong
  • find their UTR more easily when we provide help appropriate to the type of business

We need more research. If you have used Unique Taxpayer Reference, get in touch to share your research findings.

Discuss Unique Taxpayer Reference on GitHub