What are ethereum accounts and addresses, how do they relate to public keys?

  1. Generate random private key.
  2. Generate public key using ECDSA.
  3. Get public address by taking last 20 bytes of Keccak-256 hash of the public key, and adding 0x.

Other notes

You can generate more than 1 public key from your private key.

You will need a private key to sign messages / transactions which output a signature.

The signature can then be used to derive your public key, and prove you are the author of the message.

They are the first 20 bytes of the SHA3 hashed public key.


See also: Why are ethereum addresses hashes of public keys?