Content
Error pages
Provide users with clear and helpful error pages when something goes wrong.
Contents
Provide the user with information about the error:
- Error type
- A very short description of the error in present tense such as "Page not found"
- Error details (optional)
- More details about why the error may have occured
- Suggested next steps
- Some possible next steps that the user can take to either access the content they want or report the issue
Test all links and buttons to make sure they work. Remember to do the hard work to make it simple.
Remove all the header and footer links to keep the page focused on the error. This avoids error pages looking the same as "normal" content pages.
Some of the main types of error page are:
Page not found
HTML
<h1 class="tna-heading-xl">Page not found</h1>
<p>If you typed the web address, check it is correct.</p>
<p>If you pasted the web address, check you copied the entire address.</p>
<p>If the web address is correct or you selected a link or button, <a href="https://www.nationalarchives.gov.uk/contact-us/">contact us</a> to let us help.</p>
Use a page not found if someone is trying to view a page that does not exist. This happens if someone:
- selects a link or button that takes them to a page that does not exist
- types or copies a web address for a page that does not exist
- types or copies a web address incorrectly
Restricted access
HTML
<h1 class="tna-heading-xl">Restricted</h1>
<p>You are not permitted to view this content.</p>
<p>If you typed the web address, check it is correct.</p>
<p>If you pasted the web address, check you copied the entire address.</p>
<p>If you believe you should be able to view this content, <a href="https://www.nationalarchives.gov.uk/contact-us/">contact us</a> to request access.</p>
Use a restricted access if someone is trying to view a page or resource that they shouldn't be allowed to. This can happen if:
- the user is not known (unauthenticated)
- the user is known but not allowed to view (unauthorised)
Service issue
HTML
<h1 class="tna-heading-xl">There is a problem with the service</h1>
<p>Try again in a few minutes.</p>
<p>If the web address is correct or you selected a link or button, <a href="https://www.nationalarchives.gov.uk/contact-us/">contact us</a> to let us help.</p>
Use a service issue if someone is trying to view a page that the service is currently unable to render. This can happen if:
- the server is unavailable
- the server experienced an error that wasn't handled properly
- an unknown issue occured that isn't covered by other error messages