The customers/reset_password.liquid template includes a form for visitors to enter a new password for their Customer account.

Template Considerations

Previewing reset_password.liquid

To preview the reset_password.liquid template, you must first submit the {% form 'recover_customer_password' %} form, which is found in login.liquid template. Once the form is submitted, you will receive an email with a link to the reset_password.liquid template.

Screenshot of an example password reset email

Outputting the password reset form

To output a form that visitors use to log in to their customer page, initialize the form tag with the parameter 'reset_customer_password'. Within the form, include the following:

  • Input of type password with the name attribute customer[password]
  • Input of type password with the name attribute customer[password_confirmation]
  • Input of type submit to submit the form.

Below is an example of a simple password reset form:

 {% form 'reset_customer_password' %} {{ form.errors | default_errors

<label for="password">Password</label>
<input type="password" value="" name="customer[password]" size="16" />

<label for="password_confirmation">Password Confirmation</label>

<input type="submit" value="Reset Password" />

{% endform %}