Update the page <title> when an error or confirmation message is displayed

Whenever a form returns an error or confirmation message, it is advisable to update the <title>.

In the case of a confirmation message:

<title>Confirmation - Contact | [Site name]</title>

If there is an error:

<title>Error - Contact | [Site name]</title>


It is also recommended to have this information appear first in the <title> tag.


In some situations, the title does not need to be updated because the title displayed after submission is already obvious.

For example:

  • A login form which goes directly to a profile page.
  • A button which says “Next step” as part of a multi page form.
  • A contact page that sends a preview page.


Add a comment

All fields are mandatory.

Back to top