Vanity Address Generation

Waves Tech
Waves Protocol
Published in
3 min readMay 21, 2018

Crypto addresses are effectively long strings of random characters that aren’t always easy to recognise or distinguish. That’s why personalising them with a vanity address can be fun and handy!

Generating your own vanity address for bitcoin and other cryptos is relatively straightforward, but you should bear in mind a couple of warnings.

  1. Make sure you do it yourself! There are websites that generate vanity addresses for you, but there is no way to be sure they won’t keep the private key — and therefore access to your funds! (Thanks to the magic of public key cryptography, there are split-key generators that are safe, but since there’s some extra technical overhead in using these, we’ll keep it simple for now.)
  2. Make sure the software is safe! You need an open source vanity address generator that you know can generate truly random private keys and addresses, and that isn’t going to send your keys back to someone else.

As a starting point, we suggest using this popular commandline bitcoin vanity address calculator: https://en.bitcoin.it/wiki/Vanitygen

How it works

Bitcoin addresses are generated from private keys, and there is no pattern between the key and the address. That means every address is effectively a random string of characters. If you want one that has certain properties — such as your name or a certain word at the beginning (e.g. 1Bitcoin…) — the only way to do it is to generate many, many different private keys and see if one of the corresponding addresses has the string you want. The longer that string, the harder it is to find. You can speed things up by using a GPU address generator, rather than the slower CPU, but unless you have specialist hardware and some extra expertise, it’s probably not worth looking for strings more than seven or eight characters long — unless you’re prepared to wait literally months or years.

For shorter strings, the process is pretty fast, even with a laptop computer. For example, searching for the string ‘1Bit’ takes just seconds, returning a message like this:

Difficulty: 77178
Pattern: 1Bit
Address: 1Bit7E9uM1Vbt1Mn3WKtcEXc5uJxZtgt9W
Privkey: 5KBL5J2SCzoxCu8LSbur3vCcpzQQ5kL2JdRZDAu4AmCohko7goG

(Note that an ‘easy’ string to find like this does not mean that specific private key can be guessed easily — there are many keys that map to addresses beginning with 1Bit.)

Non-bitcoin vanity addresses

If you want to generate a vanity address for a different coin, you’ll need different software. Most protocols work along similar lines, and so a slight modification of the original vanitygen software will do the job. One example can be found at https://github.com/mikeyb/vanitygen-gamecredits/blob/master/README.md

For cryptos that are built on a different codebase and aren’t supported by this, like Waves, you’ll need a different approach again.

The PyWaves project, developed by Peter Black, will help you do this. If you have a little Python experience, you can get your hands dirty with pywaves, a Python library for Waves. That enables you to create addresses and much else besides very easily. All you need is a SEED to create a Waves address. You can use pywaves to generate a random twelve-word SEED and its associated address, plus other account information.

>> pywaves.Address(seed=“”)

You’ll get a response like:

address = 3PBYbuoUptZNr2byyW8P5Em8SYmhUUSCRRo
publicKey = 8yfyWdAFdmWF2uhZTjgeVEpJDLsHkXdTPs4QqyV9FUUK
privateKey = DPSWTfdtKDJJTyAgbgKgzzH52uUTuNPPZB3SxdGjBtzq
seed = crucial topple useless file sorry change bridge route trap flower nose advance bar clinic idle
balances:
Waves = 0

Now all you have to do is pick the phrase you want to see in your address, and run that enough times to find it. However, Python and pywaves aren’t really designed for this, and you’ll be waiting around a long time if you cobble together a vanity generator using this approach. Instead, you can use the much faster and purpose-designed wallet generator: https://github.com/PyWaves/wallet-generator

The instructions on the github are pretty comprehensive, but there are lots of helpful people over at the Waves Discord if you need more to go on.

--

--

Waves Tech
Waves Protocol

Waves Tech is a powerful blockchain-agnostic ecosystem focused on inter-chain DeFi, the embodiment of technological freedom for blockchain-based finance.