HTML tags appearing as plain text in error message on Registration Page

Short description of issue

On the registration page (/account/register), when a duplicate email error occurs, the error message displays raw HTML tags as plain text. I am using the standard {{ form.errors | default_errors }} liquid tag, but it seems to be escaping the HTML.

Reproduction steps

Go to the /account/register page.

Try to register with an email address that is already in the system.

The error message shows raw code containing an a tag for “Reset your password” as plain text instead of a clickable link.

Additional info

Themes tested: Dawn, Symmetry, Be Yours.

Account Type: Legacy Customer Accounts.

Current Implementation: The error is currently being rendered using: {{ form.errors | default_errors }}

The Question: How can I modify or replace {{ form.errors | default_errors }} to ensure the HTML within the error message is rendered correctly? I want the “Reset your password” link to be clickable. I have tried looping through the errors manually, but the strings still appear escaped.

Goal: To make the password reset link inside the error message functional for a better user experience.

What type of topic is this

Troubleshooting

Upload screenshot(s) of issue

Hello,
The message comes from Settings → Checkout & system → Errors.
Shopify escapes admin error HTML before Liquid renders it, and the escaping varies, so matching the full <a> tag is unreliable.

Correct approach: split the message at &lt;a and add your own link.

Thanks

1 Like