Skip to main content

These components are for prototyping the GOV.UK app, not for use in production.

<govuk-app-text>

Text

A paragraph of the app's text: Body, as most of it is, or a smaller style for details such as dates, captions and supporting information.

Native component

Examples

A paragraph

If you’re using Face ID or Touch ID to unlock the app, this will be turned off. You can turn it on again the next time you sign in. If you’re using Face ID or Touch ID to unlock the app, this will be turned off. You can turn it on again the next time you sign in.

HTML

<govuk-app-text>If you’re using Face ID or Touch ID to unlock the app, this will be turned off. You can turn it on again the next time you sign in.</govuk-app-text>

Each size

Body Callout Subheadline Footnote Caption 1 Caption 2 Body Callout Subheadline Footnote Caption 1 Caption 2

HTML

<govuk-app-text>Body</govuk-app-text>
<govuk-app-text size="callout">Callout</govuk-app-text>
<govuk-app-text size="subheadline">Subheadline</govuk-app-text>
<govuk-app-text size="footnote">Footnote</govuk-app-text>
<govuk-app-text size="caption-1">Caption 1</govuk-app-text>
<govuk-app-text size="caption-2">Caption 2</govuk-app-text>

Emphasised, and secondary

Your MOT expires on 14 March 2027 Last checked today at 9:41am Your MOT expires on 14 March 2027 Last checked today at 9:41am

HTML

<govuk-app-text emphasis>Your MOT expires on 14 March 2027</govuk-app-text>
<govuk-app-text size="subheadline" colour="secondary">Last checked today at 9:41am</govuk-app-text>

Centred, under a centred heading

Find out about things like important dates and deadlines, services you might find useful and new features that have been added to the app. Find out about things like important dates and deadlines, services you might find useful and new features that have been added to the app.

HTML

<govuk-app-text align="center">Find out about things like important dates and deadlines, services you might find useful and new features that have been added to the app.</govuk-app-text>

Inputs

Attributes
Attribute Type Default Description
size "title-1" | "body" | "callout" | "subheadline" | "footnote" | "caption-1" | "caption-2" body The text style it is drawn in. title-1 is Title 1, regular, larger than Body, as the app sets the text on its green screens.
emphasis boolean false Draws it semibold, as GovKit's bodySemibold and the like.
colour "primary" | "secondary" primary secondary: grey, text.secondary, for supporting text such as a date or a hint.
align "start" | "center" start center, under a centred heading, as on the app's onboarding and information screens.

Content

The paragraph's text. A few words of it can be bold, in a <govuk-app-strong>.

Outputs

None.

Rules

  • Use Body for a screen's text. Use a smaller style only for supporting details, as the app does: Subheadline or Footnote for a date or a label, Caption for the smallest notes.
  • Use Title 1 only for the few lines of a screen that takes over the app, such as a green one, as the app does.
  • Use one text element for each paragraph. A screen spaces them 16pt apart.
  • Use emphasis sparingly, for a word or line that has to stand out. For a heading, use the heading.
  • Use the secondary colour only for supporting text, never for something the user must read to act.
  • Centre text only under a centred heading.

When not to use it

When Use instead
For a screen's title, or a section's govuk-app-heading
For a few words that say what the rest of a line is govuk-app-strong
For a few points that are read together govuk-app-bulleted-list
For a name and postal address govuk-app-address
For something the user should know now, set apart from the screen govuk-app-banner

Sources

The iOS, Android and Figma sources it was built from

In the app

Screenshots of the app's own component, to compare the examples with

iOS

iOS app: Body: the sign-out confirmation's text, in light mode
Body: the sign-out confirmation's text, in light mode
iOS app: Body, in dark mode
Body, in dark mode