Real secp256k1 cryptography · Multi-thread Web Workers · NVIDIA GPU support (BitCrack)
Important
This is a lottery, not an exploit. The keyspace is 2²⁵⁶ ≈ 10⁷⁷ — even a billion-keys-per-second GPU farm running for the entire age of the universe wouldn't dent it. Every key generated here is a real cryptographic attempt, but the math is not on your side. The project is educational / aesthetic.
A Next.js + React webapp that generates real Bitcoin private keys in your browser using the actual secp256k1 elliptic curve, derives the corresponding P2PKH address, and checks it against all 21,953 known wallets mined by Satoshi Nakamoto between 2009 and 2010 (the Patoshi pattern, identified by Sergio Lerner). Combined balance: ~1,097,650 BTC — untouched since the genesis era.
If a match is found, the private key is downloaded as a .txt file, persisted to localStorage, and POSTed to a Next.js API route that appends it to found_keys.txt in the project root.
For real horsepower, the project also ships a sidecar setup for BitCrack (open-source CUDA Bitcoin brute-forcer) with a PowerShell wrapper that enforces a GPU temperature budget via nvidia-smi. A live dashboard card pulls nvidia-smi + BitCrack progress into the same UI.
- 🔐 Real cryptography — no simulation.
@noble/secp256k1+@noble/hashes(SHA-256, RIPEMD-160), fetched as self-contained ESM bundles and run inside module Web Workers. - 🧵 Multi-threaded — one worker per CPU logical core (configurable slider, up to 2× core count).
- 💾 O(1) lookups — all 21,953 hash160 fingerprints preloaded into a
Map. Each generated key is checked against the full target set at constant cost. - 🎮 GPU sidecar (optional) —
BitCrackCUDA binary drives an NVIDIA card at ~350 M+ keys/sec on a 3090. Live stats stream into the web UI via/api/gpu-status. - 🌡️ Temperature watchdog — PowerShell wrapper monitors
nvidia-smiand reduces the GPU power limit if temperature exceeds the target (default 70 °C). Restores on exit. - 📥 Match handling — found keys are downloaded as
.txt, saved tolocalStorage, and appended tofound_keys.txtserver-side. - 💵 Live BTC price — Binance API, refreshed every 10 s. USD prize-pool updates in real time.
- ⚙️ Settings drawer — change thread count live (restarts the worker pool), see WebGPU device info, toggle save-on-match.
- 🎨 Modern dark UI — Inter + JetBrains Mono, layered shadows, dimensional surfaces. No CRT cosplay.
Requires Node.js 20+.
git clone https://github.com/Teylersf/satoshi-cracker.git
cd satoshi-cracker
npm install
npm run devOpen http://localhost:3000.
For production:
npm run build && npm start┌───────────────────────────────────────────────────────────────────────┐
│ Browser │
│ ┌─────────────────────┐ spawns N module workers │
│ │ <Cracker /> tsx │ ──▶ each worker imports the bundled @noble │
│ │ (React 19) │ libs from blob: URLs (fetched once on │
│ │ │ the main thread to avoid CORS issues) │
│ │ - settings drawer │ │
│ │ - live stats UI │ │
│ │ - match overlay │ │
│ └─────────┬───────────┘ │
│ │ │
│ │ poll every 2 s │
│ ▼ │
│ ┌────────────────────────────┐ nvidia-smi ┌──────────────────┐ │
│ │ /api/gpu-status (Node) │ ──────────────▶│ RTX 3090 / etc. │ │
│ └────────────────────────────┘ └──────────────────┘ │
│ ┌────────────────────────────┐ │
│ │ /api/save-match (Node) │ ──▶ appends to ./found_keys.txt │
│ │ /api/found-keys (Node) │ ──▶ reads ./found_keys.txt │
│ └────────────────────────────┘ │
└───────────────────────────────────────────────────────────────────────┘
▲
│ POSTs any match
┌───────────────┴────────────────┐
│ scripts/gpu-watcher.mjs │
│ tails gpu/gpu_found.txt │
└───────────────┬────────────────┘
│
┌───────────┴────────────┐
│ cuBitCrack.exe │
│ driven by │
│ scripts/run-bitcrack │
│ with temp watchdog │
└────────────────────────┘
satoshi-cracker/
├── app/
│ ├── layout.tsx # SEO metadata, fonts, JSON-LD
│ ├── page.tsx # Page entry → renders <Cracker/>
│ ├── Cracker.tsx # Main client component (engine + UI)
│ ├── globals.css # All styles (dark / dimensional)
│ ├── sitemap.ts # /sitemap.xml
│ ├── robots.ts # /robots.txt
│ ├── opengraph-image.tsx # /opengraph-image (dynamic OG card)
│ └── api/
│ ├── save-match/route.ts # POST: append match to found_keys.txt
│ ├── found-keys/route.ts # GET: read found_keys.txt
│ └── gpu-status/route.ts # GET: nvidia-smi + BitCrack log
├── public/
│ └── satoshi-data.js # 21,953 hash160 → [address, btc] map
├── scripts/
│ ├── export-addresses.mjs # gpu/addresses.txt extractor
│ ├── setup-gpu.ps1 # Clone+build BitCrack
│ ├── run-bitcrack.ps1 # Temp-guarded runner
│ ├── gpu-watcher.mjs # GPU output → /api/save-match
│ └── fix-cuda-integration.ps1# Copies CUDA props into VS BuildTools
├── gpu/
│ └── SETUP_GPU.md # GPU mode walkthrough
├── .github/
│ ├── workflows/ci.yml # Build & type-check on push/PR
│ └── dependabot.yml # Weekly npm + monthly actions updates
├── package.json
├── tsconfig.json
└── next.config.mjs
- On mount,
<Cracker/>injects/satoshi-data.jsas a<script>tag. That file defineswindow.SATOSHI_HASH160(aMap<hash160, [address, btc]>) andwindow.SATOSHI_TOTAL_BTC. - The component fetches bundled
@noble/secp256k1and@noble/hashesmodules fromcdn.jsdelivr.neton the main thread (where cross-origin redirects work normally), wraps them in localblob:URLs, and rewrites internal relative references so the bundle is self-contained. - A pool of
Worker(blobUrl, { type: 'module' })is spawned — one per requested thread. Each worker imports the blob URLs (no redirects → no Chromium module-worker policy violations) and loops:utils.randomPrivateKey()→ 32 random bytessecp256k1.getPublicKey(pk, false)→ 65-byte uncompressed pubkeyRIPEMD160(SHA256(pubkey))→ 20-byte hash160map.get(hash160)→ hit / miss in constant time, against all 21,953 targets simultaneously
- Workers post a
statsmessage every ~350 ms (counter + last sample for display). On a match they postmatchand the main thread takes over: persist, download, POST to the API. - If module workers fail (e.g. unusual CSP), a single-threaded
requestAnimationFramefallback kicks in using the same noble libs imported via dynamicimport()of blob URLs.
Open with the ⚙ button in the top bar.
| Setting | Behavior |
|---|---|
| CPU Threads | Slider from 1 to 2 × hardwareConcurrency. Default = min(cores, 16). "Apply Threads" tears down the worker pool and respawns. Going above logical core count is allowed but warned against. |
| GPU Acceleration | Disabled — see GPU Mode for real GPU support. |
| Save Match to Server + Download | When ON: /api/save-match appends to found_keys.txt AND your browser downloads satoshi_match_<timestamp>.txt. |
| Reset Stats | Zero counters + clear log. |
The browser cannot drive your GPU for secp256k1 brute force. Porting 256-bit elliptic-curve math to WGSL is a multi-month research project. This project doesn't fake it.
What it does ship: a one-command setup for BitCrack (native CUDA tool) with a Windows PowerShell wrapper that:
- Clones + builds BitCrack on first run
- Generates
gpu/addresses.txtfrompublic/satoshi-data.js - Runs
cuBitCrack.exewith a temp guard:- sets
nvidia-smi -pl 250(out of 350 W TDP for a 3090) to cap natural draw - polls
nvidia-smi --query-gpu=temperature.gpuevery 5 s - drops the limit 10 W if temp exceeds target (default 70 °C), with a floor of 150 W
- raises it back when temp stays cool for a full minute
- restores the original limit on exit
- sets
- Tees BitCrack's stdout to
gpu/bitcrack.logso/api/gpu-statuscan parse it - The web UI's "GPU — Native Brute Force" card pulls live
nvidia-smi+ BitCrack progress every 2 s
# In a separate shell (Admin shell to enable the soft power cap):
npm run gpu:setup # one-time: clone + build BitCrack
npm run gpu:run # start GPU brute force with temp guard
npm run gpu:watch # bridge gpu_found.txt → /api/save-matchPrerequisites (the setup script detects and reports missing pieces):
- NVIDIA driver (
nvidia-smi) - CUDA Toolkit 12.x (
nvcc) — https://developer.nvidia.com/cuda-downloads - Visual Studio 2022 Build Tools + "Desktop development with C++" workload
- Git for Windows
Full walkthrough including patches applied to BitCrack for CUDA 12 + Ampere compatibility: see gpu/SETUP_GPU.md.
Realistic throughput on a 3090: ~1–3 billion keys/sec on bare metal. With this Tee-Object pipeline you'll see ~350 MKey/sec (Windows console I/O overhead). Probability of finding a Patoshi key in a human lifetime: still indistinguishable from zero. The card will be fully engaged, though.
| Method | Path | Purpose |
|---|---|---|
GET |
/api/found-keys |
Read the contents of found_keys.txt. Returns plain text. |
POST |
/api/save-match |
Append a match. Body: { privkey, address, btc, usd }. |
GET |
/api/gpu-status |
nvidia-smi stats + parsed BitCrack progress. Returns JSON. |
When a match is found, /api/save-match appends an entry like this to found_keys.txt in the project root:
==================== MATCH FOUND ====================
Timestamp: 2026-05-18 22:14:08
Private Key: 5KJ... (full 256-bit hex)
Address: 1A1zP1eP5QGefi2DMPTfTL5SLmv7DivfNa
BTC Balance: 50.00000000 BTC
USD Value: $3,849,968.00
Source: Satoshi Cracker (Next.js)
=====================================================
The page reads this file via GET /api/found-keys on mount and renders the Found Keys card.
Caution
found_keys.txt is gitignored by default. Never commit it. Anyone with the private key controls the corresponding wallet — broadcasting a transaction from a Patoshi address would be globally visible and a magnet for front-running bots.
- No "already tried" key database. Random 256-bit draws collide with probability ~2⁻¹²⁸ — you can run for the age of the universe and never repeat. Storing tried keys wastes disk for zero benefit.
- No fake GPU slider. If the browser can't actually dispatch work to the GPU, the UI says so. Real GPU work is the BitCrack sidecar.
- No telemetry / analytics. The page makes exactly four outbound requests: Binance for BTC/USD, jsdelivr for the noble libs (only once, cached), Google Fonts for typography, and (only after deploy) Vercel Analytics if you wire it.
The project is a standard Next.js 15 App Router app — deploys to any platform that supports Node 20+. Tested on Vercel:
- Push to GitHub (you're reading this from there)
- https://vercel.com/new → import the repo
- Set
NEXT_PUBLIC_SITE_URLto your production domain (used bysitemap.ts,robots.ts, and OG metadata) - Deploy
The /api/save-match, /api/found-keys, and /api/gpu-status routes use the Node.js runtime (not Edge) because they read/write the filesystem and shell out to nvidia-smi. On Vercel's read-only filesystem the file-write routes are no-ops; for a real deployment with persistent found-key logging, deploy to your own server / VPS.
- Framework: Next.js 15 (App Router)
- Runtime: React 19, Node.js 20+
- Crypto:
@noble/secp256k1,@noble/hashes— audited, zero-dependency JavaScript implementations - CDN: jsdelivr's
/+esmfor self-contained ESM bundles - Language: TypeScript 5 (strict mode)
- Styling: Plain CSS in
globals.css— no Tailwind, no CSS-in-JS - Fonts: Inter (UI) + JetBrains Mono (hex/code)
- GPU sidecar: BitCrack (C++/CUDA, GPL-2.0)
- Original single-file version (HTML/CSS/JS): https://github.com/swompythesecond/satoshicracker
- Patoshi pattern analysis: Sergio Lerner
- secp256k1 reference implementation: Bitcoin Core's
libsecp256k1 - BitCrack: @brichard19
MIT © Taylor Kalin. Use freely. The author takes no responsibility for electricity bills or existential dread.