create2-vanity
Grind a deterministic contract address by searching CREATE2 salts, in your
browser, then check it is actually free on every chain before you deploy.

Try it without installing anything: npx wrangler deploy --temporary puts this
whole thing (site, API and discovery documents) on a Cloudflare Workers URL in
about thirty seconds and needs no account, no token and no configuration. That
preview is disposable and gets a fresh subdomain every time; npx wrangler deploy
with a Workers-scoped token puts it somewhere permanent.
npx create2-vanity grind --init-code-hash 0x30f9… --prefix beef
npx create2-vanity available 0xBEEF…
A complete tool for deterministic deployments: the browser grinder, the site, an
HTTP API, a CLI, an MCP server, cross-chain availability checks, a one-click
deploy through the Arachnid proxy, and EIP-712 grind attestations whose central
claim any verifier recomputes.
There is no key here
EIP-1014 defines the address:
address = keccak256(0xff ‖ deployer ‖ salt ‖ keccak256(initCode))[12:]
Four public inputs, one hash, twenty bytes out. No private key appears
anywhere in that expression, and that single fact changes the whole risk model
compared with a wallet grinder:
- a hostile grinder's worst case is a salt that does not work, disproved by one
keccak;
- the work can be delegated to anyone, on any machine, with nothing to protect;
- server-side grinding is on by default here, because refusing to do it would
be theatre (the wallet-side sibling, evm-vanity,
disables its equivalent endpoint for exactly the opposite reason);
- an attestation about the address is checkable, not merely signed.
Three things this does that other CREATE2 tools do not
1. It refuses to let you hash the wrong thing
Init code is the deploy bytecode with the ABI-encoded constructor arguments
appended. Hashing the bytecode alone is the most common reason a predicted
address turns out wrong, and it is discovered after the grind, after the
deployment, and after the money.
Drop a Foundry or Hardhat artifact onto the grinder page, or point the CLI at
it, and the tool reads the bytecode, reads the ABI, and tells you in red exactly
which constructor arguments are still missing:
$ create2-vanity hash --artifact out/Token.sol/Token.json
✦ 0x9c2f…
Token, 4210 bytes of deploy code
This contract takes 2 constructor arguments:
address owner
uint256 cap
The hash above covers the deploy code alone. Append the ABI-encoded arguments
before grinding, or the address you find is not the address you deploy to.
2. It knows that portability is not availability
The same deployer, init code and salt give the same address on every chain where
that deployer exists. That is the reason to use CREATE2, and it comes with a
failure mode nobody warns about: the address can already be occupied on one
chain while it is free on the rest.
$ create2-vanity available 0x00000000D49195AE81759cd247cFeDD9D0B479df
Ethereum free
Base occupied
Arbitrum One occupied
Robinhood Chain free
…
occupied on 2 chains: deploying there would fail or hit someone else's contract.
That is a real address with a real split. The deploy page checks
every chain first, and re-checks the chain you picked immediately before signing,
because a table can be minutes old by the time anyone clicks.
3. Its attestations do not ask to be trusted
A grind attestation records who ground a salt, when, and how many attempts it
took, signed as EIP-712 typed data so a contract can recover the signer with
ecrecover. Its central claim is not a claim at all: the verifier re-derives the
address from the attested deployer, salt and init-code hash, so a lie fails in
one keccak with or without the signature.
const result = verifyAttestation(attestation, { issuers });
result.checks.find((c) => c.id === 'derivation').pass; // needs no issuer at all
Losing the issuer key would cost this service its identity and cost users
nothing. That is the correct amount of authority for a tool like this to hold.
Install and run
git clone https://github.com/nirholas/create2-vanity
cd create2-vanity
npm install
npm run dev # site on http://localhost:5182, API on http://localhost:8789
npm test # 43 tests
Production, Cloudflare Workers, Docker and Cloud Run: docs/deploy.md.
Install the CLI and library from npm:
npm install create2-vanity