Scrypt Hash Generator — Memory-Intensive Password Hashing
Hash or verify with tunable N, r, and p parameters — scrypt's memory-hard design defeats GPU and ASIC brute-force. Everything runs locally in your browser.
What is Scrypt Key Derivation?
Memory-hard by design — scrypt forces crackers to burn gigabytes of RAM, so GPU and ASIC brute-force fails. Protect passwords with a hash designed to consume lots of memory.
Scrypt is a memory-hard password-based key derivation function (KDF) designed by Colin Percival in 2009 to resist hardware acceleration attacks. Unlike fast hashes, scrypt forces attackers to commit large amounts of RAM per attempt — the memory you configure (typically 32-128 MB) becomes the attacker's bottleneck, defeating GPU and ASIC brute-force rigs. Use this tool to derive password hashes or encryption keys with tunable N, r, and p parameters, or to verify an existing scrypt hash. The computation runs entirely in your browser; nothing is sent to a server.
Zero-Server Tool Data Guarantee
All hashing and verification happens locally in your browser. Your password and salt are never sent to any server.
How to Use
Hash or Verify
Use Hash to generate a scrypt key, or Verify to inspect and test an existing encoded scrypt hash string.
Apply a Preset
Pick a cost preset (OWASP interactive N=131072, Encryption N=65536, or Lightweight N=8192) to set parameters in one click, or choose Custom to enter log2(N), r, p, and key length manually.
Generate or enter a salt
Use the Generate button for a cryptographically random 16-byte salt, or paste your own. The salt is required and must be stored with the hash.
Extract the Key
The derived key is calculated in your browser. Copy it as an Encoded string (recommended — includes parameters and salt), or as hex/base64 for use in your security implementations.
Inspect Parsed Params
In Verify mode, paste an encoded scrypt hash to see its parsed N, r, p, len, and salt before checking for a match.
Common Use Cases
Password Storage
Derive a storage-safe key from a user password. The memory-hard property makes GPU-based cracking farms impractical.
Encryption Key Derivation
Turn a passphrase into an AES-256 encryption key for encrypting files, databases, or backups.
Cryptocurrency Wallets
Protect crypto wallets with scrypt-derived keys, leveraging its resistance to specialized mining hardware.
Secure API Authentication
Derive short-lived API tokens from master credentials using scrypt with a per-request unique salt.
Implementation Examples
import { scrypt } from 'scrypt-js';async function deriveKey(password, salt) {const passwordBytes = new TextEncoder().encode(password);const saltBytes = new TextEncoder().encode(salt);const dk = await scrypt(passwordBytes, saltBytes, {N: 16384, r: 8, p: 1, dkLen: 32});return Array.from(dk).map(b => b.toString(16).padStart(2, '0')).join('');}
Scrypt vs Bcrypt vs Argon2
| Feature | Scrypt | Bcrypt | Argon2 |
|---|---|---|---|
| Memory hardness | High (configurable) | Low (4KB fixed) | High (configurable) |
| GPU/ASIC resistance | Strong | Moderate | Strongest |
| Parameters | N, r, p | Cost factor only | Memory, iterations, parallelism |
| Winner of Password Hashing Competition | No | No | Yes (2015) |
| Library availability | Good | Excellent | Good (growing) |
| Best for | Crypto / high-security | Web apps (simple) | New projects (recommended) |
Production Best Practices & Security
Frequently Asked Questions
scrypt is a password-based key derivation function (KDF) designed by Colin Percival in 2009, originally created for the Tarsnap backup service.
Unlike fast hash functions like SHA-256 that can be computed billions of times per second, scrypt is deliberately memory-hard. It requires a configurable amount of RAM (typically 8-128 MB) to compute each hash.
This memory requirement is its key advantage. An attacker using a GPU or ASIC can't just throw more compute at the problem, because each parallel hash attempt needs its own chunk of memory. Memory bandwidth becomes the real bottleneck.
scrypt makes brute-force and dictionary attacks dramatically more expensive than algorithms like PBKDF2, which are compute-bound but not memory-hard.