We need to know your nationality so we can work out which elections you’re entitled to vote in. If you cannot provide your nationality, you’ll have to send copies of identity documents through the post.
Kitchen sink
All GOV.UK Design System component examples on one page
Accordion
# default
- Example item 2
# with additional descriptions
We need to know your nationality so we can work out which elections you’re entitled to vote in. If you cannot provide your nationality, you’ll have to send copies of identity documents through the post.
- Example item 1
- Example item 2
# with long content and description
- Example item 1
- Example item 2
# with all sections already open
# classes
Some content
# attributes
Some content
# custom heading level
Some content
# heading html
Some content
# with falsy values
Some content
Some content
# with remember expanded off
Some content
# with focusable elements inside
# with one section open
- Example item 2
# with translations
We need to know your nationality so we can work out which elections you’re entitled to vote in. If you cannot provide your nationality, you’ll have to send copies of identity documents through the post.
- Example item 2
Back link
# default
Back# inverse
Back# classes
Back# html as text
<b>Home</b># html
Back# with custom text and link
Back to home# attributes
BackBreadcrumbs
# default
# with one level
# without the home section
# with last breadcrumb as current page
# with collapse on mobile
# inverse
# classes
# attributes
# item attributes
# html as text
# html
# custom label
Button
# default
# disabled
# link
Link button# start
# input
# secondary
# warning
# inverse
# attributes
# link attributes
Submit# input attributes
# classes
# link classes
Submit# input classes
# name
# type
# input type
# explicit link
Continue# no href
Submit# value
# html
# no type
# no data-prevent-double-click
# don't prevent double click
# id
# start link
Start now link button# input disabled
# prevent double click
Character count
# default
# with hint
# with hint and error
# with default value
# with default value exceeding limit
# with custom rows
# with label as page heading
# with word count
# with threshold
# with custom textarea description
# classes
# id
# attributes
# formGroup with classes
# custom classes on countMessage
# spellcheck enabled
# spellcheck disabled
# custom classes with error message
# with id starting with number
# with id with special characters
# with textarea maxlength attribute
# to configure in JavaScript
# when neither maxlength nor maxwords are set
# when neither maxlength/maxwords nor textarea description are set
# with translations
Checkboxes
# default
# with hint
# with pre-checked values
# with divider and None
# with divider, None and conditional items
# with hints on items
# with legend as a page heading
# with error message
# with very long option text
# with conditional items
# with optional form-group classes showing group error
# small
# small with long text
# small with error
# small with hint
# small with conditional reveal
# small with divider and None
# with id and name
# with disabled item
# with idPrefix
# with falsy values
# classes
# with fieldset describedBy
# attributes
# with checked item
# items with attributes
# empty conditional
# with label classes
# multiple hints
# with conditional items with special characters
# with error message and hint
# with error, hint and fieldset describedBy
# label with attributes
# fieldset params
# fieldset html params
# with single option set 'aria-describedby' on input, and describedBy
# with single option (and hint) set 'aria-describedby' on input, and describedBy
# with error and idPrefix
# with error message and fieldset describedBy
# with conditional item checked
# item checked overrides values
# textarea in conditional
Cookie banner
# default
# accepted confirmation banner
# rejected confirmation banner
# with html
# heading html
# heading html as text
# html
# classes
# attributes
# custom aria label
# hidden
# hidden false
# default action
# link
# link with false button options
# link as a button
# type
# button classes
# button attributes
# link classes
# link attributes
# client-side implementation
# full banner hidden
# rebrand
Date input
# default
# day and month
# month and year
# with errors only
# with errors and hint
# with error on day input
# with error on month input
# with error on year input
# classes
# attributes
# with items
# with empty items
# custom pattern
# custom inputmode
# with nested name
# with id on items
# suffixed id
# with values
# with hint and describedBy
# with error and describedBy
# fieldset html
# items with classes
# items without classes
# with optional form-group classes
# with autocomplete values
# with input attributes
Details
# default
Help with nationality
# expanded
Help with nationality
# id
Expand this section
# html as text
Expand this section
# html
Expand this section
# summary html as text
The greater than symbol (>) is the best
# summary html
Use bold text sparingly
# classes
Expand me
# attributes
Expand me
# with html
Where to find your National Insurance Number
- your National Insurance card
- your payslip
- P60
- benefits information
- tax return
Error message
# default
# translated
# id
# classes
# html as text
# html
# attributes
# with visually hidden text
# visually hidden text removed
Error summary
# default
# without links
There is a problem
- Invalid username or password
# mixed with and without links
There is a problem
- Invalid username or password
- Agree to the terms of service to log in
# with description only
There is a problem
The file couldn't be loaded. Try again later.
# with everything
There is a problem
Please fix the errors below.
- Invalid username or password
- Agree to the terms of service to log in
# html as titleText
Alert, <em>alert</em>
- Invalid username or password
# title html
Alert, alert
- Invalid username or password
# description
There is a problem
Lorem ipsum
- Invalid username or password
# html as descriptionText
There is a problem
See errors below (>)
- Invalid username or password
# description html
There is a problem
See errors below
- Invalid username or password
# classes
There is a problem
- Invalid username or password
# attributes
There is a problem
- Invalid username or password
# error list with attributes
There is a problem
# error list with html as text
There is a problem
- Descriptive link to the <b>question</b> with an error
# error list with html
There is a problem
- The date your passport was issued must be in the past
# error list with html link
There is a problem
# error list with html as text link
There is a problem
# autofocus disabled
There is a problem
# autofocus explicitly enabled
There is a problem
Exit this page
# default
# testing
# testing-html
# translated
Fieldset
# default
# styled as xl text
# styled as large text
# styled as medium text
# styled as small text
# as page heading xl
# as page heading l
# as page heading m
# as page heading s
# as page heading without class
# html fieldset content
# with describedBy
# html as text
# html
# legend classes
# classes
# role
# attributes
File upload
# default
# with hint text
# with error message and hint
# with label as page heading
# enhanced
# enhanced, with error message and hint
# enhanced, multiple files
# with value
# attributes
# classes
# id
# with describedBy
# with hint and describedBy
# error
# with error and describedBy
# with error, describedBy and hint
# translated, no javascript enhancement
# allows multiple files
# disabled
# with optional form-group classes
# translated
Footer
# default
# with custom HTML content licence and copyright notice
# with custom text content licence and copyright notice
# with custom meta
# with meta links and meta content
# with default width navigation (one column)
# with default width navigation (two columns)
# with navigation
# Full GDS example
# Three equal columns
# attributes
# classes
# with container classes
# with HTML passed as text content
# with empty meta
# with empty meta items
# with meta
# meta html as text
# with meta html
# with meta item attributes
# with empty navigation
# with navigation item attributes
# rebrand
Header
# default
# with service name
# with service name but no service url
# with navigation
# with custom menu button text
# with service name and navigation
# with large navigation
# with product name
# full width
# full width with navigation
# with full width border
# navigation item with html
# navigation item with text without link
# with St. Edward's Crown
# attributes
# classes
# custom homepage url
# with custom navigation label
# navigation item with attributes
# navigation item with html as text
# navigation item with html without link
# with custom menu button label
# with custom navigation label and custom menu button text
# empty navigation array
# rebrand
# with service name and navigation and rebrand
# with product name and rebrand
Hint
# default
# with html
# classes
# id
# html as text
# attributes
Input
# default
# with hint text
# with error message
# with error and hint
# with width-2 class
# with width-3 class
# with width-4 class
# with width-5 class
# with width-10 class
# with width-20 class
# with width-30 class
# with label as page heading
# with prefix
# with suffix
# with prefix and suffix
# with prefix and suffix and error
# with prefix and suffix and width modifier
# with extra letter spacing
# classes
# id
# custom type
# value
# zero value
# with describedBy
# attributes
# hint with describedBy
# error with describedBy
# with error, hint and describedBy
# inputmode
# with prefix with html as text
# with prefix with html
# with prefix with classes
# with prefix with attributes
# with suffix with html as text
# with suffix with html
# with suffix with classes
# with suffix with attributes
# with customised input wrapper
# with optional form-group classes
# with autocomplete attribute
# with pattern attribute
# with spellcheck enabled
# with spellcheck disabled
# with autocapitalize turned off
# disabled
Inset text
# default
# with html
It can take up to 8 weeks to register a lasting power of attorney if there are no mistakes in the application.
It can take up to 8 weeks to register a lasting power of attorney if there are no mistakes in the application.
# classes
# id
# html as text
# attributes
Label
# default
# with bold text
# styled as xl text
# styled as large text
# styled as medium text
# styled as small text
# as page heading xl
# as page heading l
# as page heading m
# as page heading s
# as page heading without class
# empty
# classes
# html as text
# html
# for
# attributes
Notification banner
# default
# with text as html
# with type as success
# with long heading
# with lots of content
# custom title
# title as html
# title html as text
# custom title heading level
# custom title id
# custom title id with type as success
# custom text
# html as text
# custom role
# classes
# attributes
# with invalid type
# auto-focus disabled, with type as success
# auto-focus explicitly enabled, with type as success
# role=alert overridden to role=region, with type as success
# custom tabindex
Pagination
# default
# with custom link and item text
# with many pages
# first page
# last page
# with prev and next only
# with prev and next only and labels
# with prev and next only and very long labels
# with previous only
# with next only
# with custom classes
# with custom attributes
# with custom navigation landmark
# with custom accessible labels on item links
Panel
# default
Application complete
# title html as text
Application <strong>not</strong> complete
# title html
Application not complete
# body html as text
Application complete
# body html
Application complete
HDJ2123F
# classes
Application complete
# attributes
Application complete
# title with no body text
Application complete
# custom heading level
Application complete
Password input
# default
# with hint text
# with error message
# with label as page heading
# with input width class
# classes
# id
# value
# attributes
# with describedBy
# with new-password autocomplete
# with translations
Phase banner
# default
# classes
# text
# html as text
# attributes
# tag html
# tag classes
Radios
# default
# with hint
# inline
# with legend as page heading
# with a divider
# with hints on items
# without fieldset
# with fieldset and error message
# with very long option text
# with conditional items
# with conditional item checked
# with optional form-group classes showing group error
# small
# small with long text
# small with error
# small with hint
# small with conditional reveal
# small inline
# small with a divider
# with idPrefix
# minimal items and name
# with falsy items
# fieldset with describedBy
# attributes
# items with attributes
# with empty conditional
# label with classes
# with hints on parent and items
# with describedBy and hint
# with error message
# with error message and idPrefix
# with hint and error message
# with hint, error message and describedBy
# label with attributes
# fieldset params
# fieldset with html
# with fieldset, error message and describedBy
# item checked overrides value
# textarea in conditional
# with disabled
# prechecked using value
# with conditional items with special characters
# with conditional items and pre-checked value
Select
# default
# with hint text and error message
# with label as page heading
# with full width override
# with describedBy
# attributes
# attributes on items
# with falsy items
# hint
# hint and describedBy
# error
# error and describedBy
# without values
# without values with selected value
# with falsy values
# item selected overrides value
# id
# with selected value
# with optional form-group classes
Service navigation
# default
# with navigation with a current item
# with large navigation
# with HTML navigation items
# with non-link navigation items
# with service name
# with service link
# with long service name
# with service name and navigation
# inverse
# with collapseNavigationOnMobile set to false
# with a single navigation item
# with a single navigation item and collapseNavigationOnMobile set to true
# with no options set
# attributes
# classes
# with custom aria-label
# with custom navigation toggle text
# with custom navigation toggle label
# with identical navigation toggle text and label
# with custom navigation label
# with custom navigation toggle text and navigation label
# with custom navigation classes
# with custom navigation ID
# with navigation having empty values
# with navigation having only empty values
# with navigation being an empty array
# with navigation with an active item
# with slotted content
# rebrand
Skip link
# default
Skip to main content# with focus
Skip to main content# no href
Skip to main content# custom href
Skip to custom content# custom text
skip# html as text
<p>skip</p># html
skip
# classes
Skip link# attributes
Skip linkSummary list
# default
- Name
- Firstname Lastname
- Date of birth
- 13/08/1980
- Contact information
-
email@email.com
Address line 1
Address line 2
Address line 3
Address line 4
Address line 5
# with actions
- Contact information
-
email@email.com
Address line 1
Address line 2
Address line 3
Address line 4
Address line 5
# no-border
- Name
- Firstname Lastname
- Date of birth
- 13/08/1980
- Contact information
-
email@email.com
Address line 1
Address line 2
Address line 3
Address line 4
Address line 5
# no-border on last row
- Name
- Firstname Lastname
- Date of birth
- 13/08/1980
- Contact information
-
email@email.com
Address line 1
Address line 2
Address line 3
Address line 4
Address line 5
# extreme
- Name
- Barnaby Marmaduke Aloysius Benjy Cobweb Dartagnan Egbert Felix Gaspar Humbert Ignatius Jayden Kasper Leroy Maximilian Neddy Obiajulu Pepin Quilliam Rosencrantz Sexton Teddy Upwood Vivatma Wayland Xylon Yardley Zachary Usansky
- Long website address
- https://cs.wikipedia.org/wiki/Llanfairpwllgwyngyllgogerychwyrndrobwllllantysiliogogogoch
- Change long website address
- Long email address
- webmaster@llanfairpwllgwyngyllgogerychwyrndrobwllllantysiliogogogoch.com
- Change long email address
- Pneumonoultramicroscopicsilicovolcanoconiosis
-
Pneumonoultramicroscopicsilicovolcanoconiosis is a word coined by the president of the National Puzzlers’ League as a synonym for the disease known as silicosis. It is the longest word in the English language published in a dictionary, the Oxford English Dictionary, which defines it as "an artificial long word said to mean a lung disease caused by inhaling very fine ash and sand dust."
Silicosis is a form of occupational lung disease caused by inhalation of crystalline silica dust, and is marked by inflammation and scarring in the form of nodular lesions in the upper lobes of the lungs. It is a type of pneumoconiosis.
- Its vanished trees, the trees that had made way for Gatsby’s house, Pneumonoultramicroscopicsilicovolcanoconiosis had once pandered in whispers to the last and greatest of all human dreams; for a transitory enchanted moment man must have held his breath in the presence of this continent, compelled into an aesthetic contemplation he neither understood nor desired, face to face for the last time in history with something commensurate to his capacity for wonder.
- The Great Gatsby
# as a summary card with a text header
Undergraduate teaching assistant
- Name
- Firstname Lastname
- Date of birth
- 13/08/1980
# as a summary card with a html header
Undergraduate teaching assistant
- Name
- Firstname Lastname
- Date of birth
- 13/08/1980
# as a summary card with actions
Undergraduate teaching assistant
- Name
- Firstname Lastname
- Date of birth
- 13/08/1980
# as a summary card with actions plus summary list actions
Undergraduate teaching assistant
- Name
- Firstname Lastname
# as a summary card extreme
Senior mid-level customer experience enhancement consultant
- Bop it (Senior mid-level customer experience enhancement consultant)
- Twist it (Senior mid-level customer experience enhancement consultant)
- Pull it (Senior mid-level customer experience enhancement consultant)
- Flick it (Senior mid-level customer experience enhancement consultant)
- Spin it (Senior mid-level customer experience enhancement consultant)
- Shout it (Senior mid-level customer experience enhancement consultant)
- Shake it (Senior mid-level customer experience enhancement consultant)
- Name
- Barnaby Marmaduke Aloysius Benjy Cobweb Dartagnan Egbert Felix Gaspar Humbert Ignatius Jayden Kasper Leroy Maximilian Neddy Obiajulu Pepin Quilliam Rosencrantz Sexton Teddy Upwood Vivatma Wayland Xylon Yardley Zachary Usansky
-
- Buy (Senior mid-level customer experience enhancement consultant)
- Use (Senior mid-level customer experience enhancement consultant)
- Break (Senior mid-level customer experience enhancement consultant)
- Fix (Senior mid-level customer experience enhancement consultant)
- Trash (Senior mid-level customer experience enhancement consultant)
- Change (Senior mid-level customer experience enhancement consultant)
- Mail (Senior mid-level customer experience enhancement consultant)
- Upgrade (Senior mid-level customer experience enhancement consultant)
- Charge (Senior mid-level customer experience enhancement consultant)
- Point (Senior mid-level customer experience enhancement consultant)
- Zoom (Senior mid-level customer experience enhancement consultant)
- Press (Senior mid-level customer experience enhancement consultant)
- Snap (Senior mid-level customer experience enhancement consultant)
- Work (Senior mid-level customer experience enhancement consultant)
- Quick (Senior mid-level customer experience enhancement consultant)
- Erase (Senior mid-level customer experience enhancement consultant)
# attributes
- Name
- Firstname Lastname
# with falsy values
- Name
- Firstname Lastname
- Name 2
- Firstname2 Lastname2
# key with html
- Name
- Firstname Lastname
# key with classes
- Name
- Firstname Lastname
# value with html
- Name
- email@email.com
# actions href
# actions with html
# actions with classes
# actions with attributes
# single action with anchor
# classes on items
# empty items array
- Name
- Firstname Lastname
# rows with classes
- Name
- Firstname Lastname
# summary card with custom classes
- Name
- Firstname Lastname
- Date of birth
- 13/08/1980
# summary card with custom attributes
- Name
- Firstname Lastname
- Date of birth
- 13/08/1980
# summary card with only 1 action
Undergraduate teaching assistant
- Name
- Firstname Lastname
- Date of birth
- 13/08/1980
# translated
- Gwybodaeth cyswllt
-
email@email.com
Address line 1
Address line 2
Address line 3
Address line 4
Address line 5 - Golygu gwybodaeth cyswllt
# with some actions
- Date of birth
- 13/08/1980
- Contact information
-
email@email.com
Address line 1
Address line 2
Address line 3
Address line 4
Address line 5
# overridden-widths
- Contact information
-
email@email.com
Address line 1
Address line 2
Address line 3
Address line 4
Address line 5
# as a summary card with a custom header level
Undergraduate teaching assistant
- Name
- Firstname Lastname
- Date of birth
- 13/08/1980
Table
# default
| January | £85 | £95 |
| February | £75 | £55 |
| March | £165 | £125 |
# with head
| Month you apply | Rate for bicycles | Rate for vehicles |
|---|---|---|
| January | £85 | £95 |
| February | £75 | £55 |
| March | £165 | £125 |
# with head and caption
| Month you apply | Rate for bicycles | Rate for vehicles |
|---|---|---|
| January | £85 | £95 |
| February | £75 | £55 |
| March | £165 | £125 |
# classes
| Jan | Feb |
# attributes
| Jan | Feb |
# html as text
| Foo <script>hacking.do(1337)</script> |
|---|
| Foo <script>hacking.do(1337)</script> |
# html
| Foo bar |
|---|
| Foo bar |
# head with classes
| Foo | |
|---|---|
| Jan | Feb |
# head with rowspan and colspan
| Foo | |
|---|---|
| Jan | Feb |
# head with attributes
| Foo | |
|---|---|
| Jan | Feb |
# with firstCellIsHeader true
| January | £85 | £95 |
|---|---|---|
| February | £75 | £55 |
| March | £165 | £125 |
# firstCellIsHeader with classes
| Foo |
|---|
# firstCellIsHeader with html
| Foo bar |
|---|
# firstCellIsHeader with html as text
| Foo <script>hacking.do(1337)</script> |
|---|
# firstCellIsHeader with rowspan and colspan
| Foo |
|---|
# firstCellIsHeader with attributes
| Foo |
|---|
# with falsy items
| A | 1 |
| B | 2 |
| C | 3 |
# rows with classes
| Foo |
# rows with rowspan and colspan
| Foo |
# rows with attributes
| Foo |
# with small text modifier for tables with a lot of data
| January | £85 | £95 |
| February | £75 | £55 |
| March | £165 | £125 |
Tabs
# default
Contents
Past day
| Case manager | Cases opened | Cases closed |
|---|---|---|
| David Francis | 3 | 0 |
| Paul Farmer | 1 | 0 |
| Rita Patel | 2 | 0 |
Past week
| Case manager | Cases opened | Cases closed |
|---|---|---|
| David Francis | 24 | 18 |
| Paul Farmer | 16 | 20 |
| Rita Patel | 24 | 27 |
Past month
| Case manager | Cases opened | Cases closed |
|---|---|---|
| David Francis | 98 | 95 |
| Paul Farmer | 122 | 131 |
| Rita Patel | 126 | 142 |
There is no data for this year yet, check back later
# classes
# id
# title
# attributes
# item with attributes
# panel with attributes
# no item list
Contents
# empty item list
Contents
# with falsy values
# idPrefix
# html as text
# html
# tabs-with-anchor-in-panel
Contents
Tab 1
Testing that when you click the anchor it moves to the anchor point successfully
Tab 2
Tag
# default
Alpha# grey
Grey# light blue
Light blue# turquoise
Turquoise# green
Green# purple
Purple# pink
Pink# red
Red# orange
Orange# yellow
Yellow# attributes
Tag with attributes# html as text
<span>Alpha</span># html
AlphaTask list
# default
-
Completed
-
Incomplete
-
Incomplete
# forced hover state
-
Completed
-
Incomplete
-
Incomplete
# with hint text and additional states
-
Completed
-
Not started
-
Business planEnsure the plan covers objectives, strategies, sales, marketing and financial forecasts.Review
-
In progress
-
Error
-
PaymentIt will cost between £15 and £75Cannot start yet
# with all possible colours
-
Text colour
-
Secondary text colour
-
Grey
-
Blue
-
Light blue
-
Turquoise
-
Green
-
Purple
-
Pink
-
Red
-
Orange
-
Yellow
# with very long single word tags
-
Completed
-
Incomplete
-
Thisisaverylongwaytosaythatsomethingisincomplete
# custom classes
-
Status
-
Not a linkStatus
# custom attributes
-
Status
# custom id prefix
-
A LinkHint textStatus
# html passed as text
-
<strong>Linked Title</strong><strong>Hint</strong><strong>Status</strong>
-
<strong>Unlinked Title</strong><strong>Tag</strong>
# html
-
Linked TitleHintStatus
-
Unlinked TitleTag
# with empty values
-
Completed
-
Completed