Skip to Content

Creating a Password Strength Indicator


This tutorial utilizes strength.js to test the strength of your password and can be utilized on your own website's registration page.

This tutorial utilizes strength.js by Aaron Lumsden to test the strength of a password and can be utilized on your own website's registration page to inform users of the strength of their chosen password.

Below is the HTML, CSS, and JavaScript required.

Step 1 - Add the HTML below to your web page

Step 2 - Add the CSS below the main stylesheet of your website

Copy and Paste the CSS from our GitHub page at password-strength.css

Step 3 - Add the JavaScript below to a file called password.js

Step 4 - Add the includes below to the page where your password input lives


Matthieu McClintock
Contributions Editor here at Solodev. Want to be featured on the Solodev Blog? Get in touch.
Follow me on Twitter

Sign up to explore

Create an account in seconds and start building today.

Sign up for Solodev

©2024 Solodev. All rights reserved worldwide.