A privacy-first password hygiene checker built with Next.js 14, TypeScript, and Tailwind CSS. All analysis runs locally in your browser — your password never leaves your device.
- zxcvbn-ts powered strength estimation (score 0–4)
- Score label (Very Weak → Very Strong)
- Estimated crack time
- Warnings & suggestions
- Detected patterns (repeated, sequences, common words)
- Requirements checklist: length ≥ 12, lowercase, uppercase, number, symbol, not common
- Detects repeated characters (e.g.
aaaaa) - Detects keyboard patterns (e.g.
qwerty) - Detects sequential patterns (e.g.
1234,abcd) - Optional check against your name/email
- Fix-it advice with actionable recommendations
- Passphrase suggestion
- Toggle-based opt-in breach check
- Uses the Have I Been Pwned Pwned Passwords API
- k-anonymity model: only the first 5 characters of the SHA-1 hash are sent
- Comparison done locally — your password never leaves your device
- Handles rate limits and errors gracefully
| What | Where it happens |
|---|---|
| Password input | Browser only |
| Strength analysis | Browser only |
| Hygiene checks | Browser only |
| SHA-1 hashing | Browser only (WebCrypto) |
| Breach check API call | Only first 5 hex chars of SHA-1 sent |
| Password storage | Never — no localStorage, cookies, or analytics |
- Your password is SHA-1 hashed locally in the browser using the Web Crypto API.
- Only the first 5 characters (prefix) of the hash are sent to the HIBP API.
- The API returns all hash suffixes matching that prefix (~500–800 entries).
- The full hash suffix is compared locally — no plaintext password ever leaves your device.
This approach is called k-anonymity and is the industry standard for privacy-preserving breach checks.
- Next.js 14 (App Router)
- TypeScript
- Tailwind CSS
- zxcvbn-ts — strength estimation
- WebCrypto API — SHA-1 hashing
- HIBP Pwned Passwords API — breach check
src/
├── app/
│ ├── globals.css # Global styles + Tailwind
│ ├── layout.tsx # Root layout with SEO metadata
│ └── page.tsx # Landing page
├── components/
│ └── PasswordChecker.tsx # Main checker component
└── lib/
├── crypto.ts # SHA-1 helper (WebCrypto)
├── hibp.ts # HIBP k-anonymity breach check
└── hygiene.ts # Local hygiene analysis
npm install
npm run devOpen http://localhost:3000.
npm run build
npm start- Type a weak password (e.g.
password) → verify "Very Weak" score, red bar, warnings - Type a strong password (e.g.
X7#mK9!pLz$w2Qn) → verify "Very Strong" score, green bar - Check requirements checklist updates in real-time
- Type
aaaaa→ verify repeated characters detected - Type
qwerty123→ verify keyboard pattern detected - Type
abcdefgh→ verify sequential pattern detected - Enter name "John", type
john123→ verify personal info warning - Toggle breach check ON → verify privacy note appears
- Test with
password→ verify breach count shown - Test with a strong random password → verify "Not found"
- Toggle breach check OFF → verify result clears
- Click Show/Hide password toggle
- Click Clear (✕) button
- Expand "Password Best Practices" → verify tips visible
- Verify keyboard navigation (Tab through all controls)
- Verify no errors in browser console
- Verify
npm run buildpasses
Screenshots will be added after visual review.
MIT