Super Testnet v0
A small browser-native Bitcoin playground: create a test-only wallet, mine fake BTC, sign a text inscription, see it in that wallet’s collectibles, and follow its transactions into a local block.
This is a private, single-browser simulation inspired by Supertestnet. It uses real Bitcoin transaction serialization, Schnorr signatures and Taproot commit/reveal envelopes. It is not Bitcoin Core, public testnet, signet, regtest consensus, an Ord indexer, or production custody. There is no mainnet mode and no external broadcast path.
Run locally
Requires Node.js 20.19+ (Node 22 recommended) and npm.
npm ci
npm run dev
# Open http://localhost:5173
For the exact production server:
npm run build
npm start
# Open http://localhost:8080
Use localhost or HTTPS: secure-context Web Crypto and Web Locks are required. Chromium is the verified browser; recent browsers supporting Web Locks and Array.toReversed should work. No API keys, Bitcoin node, faucet, CDN, database, account or environment file is needed. Runtime assets are local. Installing dependencies requires network access; the built app makes no third-party requests. It is not an installable/offline service-worker app.
Complete the loop
- Create test wallet, or load a previously saved Super Testnet wallet JSON. Wallet creation never signs a transaction.
- Mine a block: receive 50 fake BTC immediately, without coinbase maturity.
- Enter up to 280 UTF-8 bytes of non-empty text. Review inscription shows the payload and costs without signing.
- Sign & inscribe explicitly signs a commit and a reveal locally. Fees total 1,000 fake sats; 1,000 fake sats remain in the inscription output. Both transactions enter the local mempool atomically.
- The inscription immediately appears as pending in this wallet’s collectibles. Mine again to confirm both transactions in one block.
- Open the inscription, its reveal, its commit, or its block in the integrated explorer. Raw transaction hex and witnesses are visible. Reload to verify persistence.
Wallet ownership is derived from the unspent reveal output’s script, not a disconnected UI list. New inscriptions spend ordinary change and never select collectible outputs. Loading another wallet on the same chain displays only that wallet’s collectibles.
Save test wallet exports its tagged test key, not chain history. Save complete lab exports both wallet and chain, including pending transactions, and is the portable recovery option. Loading a complete lab replaces local state after an explicit prompt. Clearing site data/resetting the lab destroys local state unless you have a backup. Explorer hash links work only with the matching local chain; they are not public explorer links. A different origin (including localhost vs Fly) has separate browser storage; use a complete lab backup to move it.
Architecture
src/adapters/wallet.js: test-wallet creation/loading, regtest-formatbcrt1paddress and explicit signing primitive. Only tagged v0 test backups can be imported; there is no arbitrary production-key input.src/adapters/chain.js: instant 50-BTC coinbase, UTXO set, package validation, mempool, synthetic blocks and replayable snapshots. Validates transaction shape, values, spent inputs, default Schnorr signatures and the supported Taproot script/control block. Exposesmine,submitPackage,coins,balance,snapshot.src/adapters/inscription.js: text envelope, commit/reveal construction, confirmation/ownership view.preparedoes not sign;inscribeis invoked only after the user’s explicit signing action.src/upstream/primitives.js: small attributed adaptations of Supertestnet’s input/output helpers. See provenance.LocalRPC: in-process read facade forgetblockcount,getblockhash,getblock,getrawtransaction. It is deliberately partial, not wire-compatible bitcoind JSON-RPC. A future Core or node_faker adapter can replace this boundary.src/storage.js: versionedlocalStoragesnapshot; index/UTXO reconstruction with transaction validation on load. One atomic storage write per operation; failed validation/quota writes do not publish partial in-memory state. Web Locks serialize mutations across tabs; storage events refresh other tabs.server.js: dependency-free static file server with security headers and/healthz. No signing, chain state, RPC, database or wallet secrets on the server.
Exact v0 limitations
- Blocks are custom JSON hashed with SHA-256, not Bitcoin block headers. No proof of work, difficulty, merkle tree, reorgs, peers, chain synchronization, coinbase maturity, halving or full consensus. Fixed 50-BTC rewards; fixed 500-sat fees per non-coinbase transaction are burned.
- Only this app’s single-input Taproot key-path and narrow
ordtext script-path templates are accepted. No general Script interpreter, legacy/SegWit-v0, timelocks, arbitrary transactions, fee estimation, transfers or replace-by-fee. Regtest-format addresses do not make the chain compatible with Bitcoin Core. Never fund these addresses elsewhere. - One inscription per reveal, 1,000-sat postage, 280 UTF-8 bytes, text only. No images, files, BRC-20, recursive inscriptions, sat rarity/ordinal numbering, general inscription discovery, transfer tracking or external Ord compatibility guarantee. Collectible outputs cannot be spent in v0.
- One active wallet per origin. Test secret and chain are unencrypted in browser storage and JSON backups. No mnemonic, password, hardware wallet, key derivation, custody service or hardened security audit. Tagged JSON is an accidental-import guard, not proof a key has never been used elsewhere. Never put production secrets in these files.
- No persistent server database, volume or shared chain. Browser storage quotas apply; large histories replay synchronously and eventually become slow. A maximum of 1,000 pending transactions (500 inscriptions) per block; complete lab imports capped at 5 MB. Built for small experiments.
- Mining signs nothing; only Sign & inscribe signs the two displayed operations. Restoring state verifies signatures but does not create new ones. Exporting backups exposes the fake wallet key in the downloaded file.
- No network security or economic assurances: a user controlling their browser can rewrite their entire private lab. Validation is useful for testing this flow, not an adversarial consensus boundary.
Verification
Verified in this worktree: 6 adapter tests and 8 Playwright tests passed (desktop and mobile), production build passed, and npm audit reported zero vulnerabilities. Browser tests also verify rollback when localStorage writes fail. Screenshots were inspected at both viewport sizes.
npm test
npx playwright install --with-deps chromium
npm run test:e2e
The adapter suite covers ownership, real signed commit/reveal construction, confirmation, RPC inspection, pending/confirmed restoration, malformed imports, UTF-8 limits, bad signatures, modified payload/control blocks, over-spending, atomic rollback, double-spending and collectible protection.
Playwright tests the production build/server, at desktop and Pixel 7 mobile sizes: full loop, review-before-signing, pending persistence, transaction/block navigation, complete backup/reset/restore, wallet imports, invalid input, two-tab concurrent mining, script-like payload safety, no third-party requests and no horizontal overflow. Screenshots/traces are written to ignored test-results/.
Independent Fly deployment
Dockerfile builds static assets and runs a non-root Node static server. fly.toml targets only supertestnet, one shared CPU, 256 MB RAM, HTTPS, health checks, scale-to-zero, and no volume or database. No Teahub app, service, secrets or network integration is configured. No custom domain is configured.
From a worker with authorized Fly CLI/account access, create the new app in the intended organization, then deploy:
fly auth whoami
fly apps create supertestnet --org YOUR_AUTHORIZED_ORG
fly deploy --app supertestnet --config fly.toml --ha=false
fly status --app supertestnet
Use --ha=false to avoid a redundant second machine. If the app name already exists, verify its ownership and purpose before deploying; do not overwrite an unrelated app. Expected URL after successful creation: https://supertestnet.fly.dev.
Current worker deployment status: not deployed. Neither fly nor flyctl is installed/on PATH, no default ~/.fly configuration is present, and no Fly credential environment variables are configured. Authorized account access could not be established; no app was created and no credentials were invented. Docker is also unavailable here, so the image was not built locally; the identical production Node server is exercised by Playwright. Fly app-name availability and deployment remain unverified.
Configuration references: Fly app configuration, Fly deploy options.
Attribution and licenses
See PROVENANCE.md for upstream commit pins, exactly what was adapted, what was only inspiration, and the node_faker decision. License texts ship in public/licenses/ and the app links them. No upstream UI, network relay, mainnet API or remote script loader was imported.