<p>1 and 3 are currently the only defined prefixes for an base58 encoded address.</p>

<p>1 is most common and denotes a simple "pay-to-PubKey" transaction. This transaction shows an actual recipient address.</p>

<p>3 indicates a "pay-to-script-hash" address that contains a hash (one way fingerprint) of a script that can be used for multiple things including address obfuscation and multi-signature requirements. This script is required to be a valid bitcoin transaction script, but the full script behind the scenes is not public, just the hash.</p>

<p>More information here:
<a href="https://en.bitcoin.it/wiki/BIP_0016" rel="nofollow">https://en.bitcoin.it/wiki/BIP_0016</a></p>

<p>More info on the base58 implementation used:
<a href="https://en.bitcoin.it/wiki/Base58Check_encoding" rel="nofollow">https://en.bitcoin.it/wiki/Base58Check_encoding</a></p>

CC BY-SA 3.0
2013-09-07T17:01:22.603Z
2013-09-07T17:09:30.583Z
2013-09-07T17:09:30.583Z
Scrybe
<p>The odd prefix comes from a different magic byte used to generate this address. 05 in this case for a script address. Magic bytes are used for different purposes, like indicating the network. Bitcoins private key byte is 0x80, or 128. (testnet is 6F, litecoin has 48, giving L..)</p>

<p>You can find a list here: <a href="https://en.bitcoin.it/wiki/List_of_address_prefixes" rel="nofollow noreferrer">https://en.bitcoin.it/wiki/List_of_address_prefixes</a></p>

<p>Usually they're defined in the chainparams.cpp  <a href="https://github.com/bitcoin/bitcoin/blob/2068f089c8b7b90eb4557d3f67ea0f0ed2059a23/src/chainparams.cpp#L129" rel="nofollow noreferrer">https://github.com/bitcoin/bitcoin/blob/2068f089c8b7b90eb4557d3f67ea0f0ed2059a23/src/chainparams.cpp#L129</a> for bitcoin and related networks, except in really old versions</p>

CC BY-SA 4.0
2013-12-20T03:32:32.540Z
2018-11-16T23:22:57.860Z
2018-11-16T23:22:57.860Z
karimkorun
<p>Here is a comprehensive list of key formats: <a href="https://en.bitcoin.it/wiki/List_of_address_prefixes" rel="nofollow">https://en.bitcoin.it/wiki/List_of_address_prefixes</a>. Technically, most of these are not addresses, but this seems to be in line with @Assaf Shomer's answer, which mentions raw private keys. </p>

CC BY-SA 3.0
2013-09-10T22:34:35.697Z
2013-09-10T22:34:35.697Z
John Henry
<p>According to the <a href="https://github.com/oleganza/CoreBitcoin/blob/master/GLOSSARY.md">glossary</a> 
the possible prefixes for bitcoin addresses are 1,3 or 5:</p>

<p>I'm quoting here:</p>

<blockquote>
  <p>Address</p>
  
  <p>Bitcoin address is a Base58Check representation of a Hash160 of a
  public key with a version byte 0x00 which maps to a prefix "1".
  Typically represented as text (ex. 1CBtcGivXmHQ8ZqdPgeMfcpQNJrqTrSAcG)
  or as a QR code.</p>
  
  <p>A variant of an address is P2SH address: a hash of a spending script
  with a version byte 0x05 which maps to a prefix "3" (ex.
  3NukJ6fYZJ5Kk8bPjycAnruZkE5Q7UW7i8).</p>
  
  <p>Another variant of an address is not a hash, but a raw private key
  representation (e.g.
  5KQntKuhYWSRXNqp2yhdXzjekYAR7US3MT1715Mbv5CyUKV6hVe). It is rarely
  used, only for importing/exporting private keys or printing them on
  paper wallets.</p>
</blockquote>

CC BY-SA 3.0
2013-09-08T05:58:27.697Z
2013-09-08T05:58:27.697Z
Assaf Shomer
<p>Until today, I thought all addresses must start with <code>1</code>.</p>

<p>Well, behold <a href="https://blockchain.info/address/3M8XGFBKwkf7miBzpkU3x2DoWwAVrD1mhk" rel="noreferrer">3M8XGFBKwkf7miBzpkU3x2DoWwAVrD1mhk</a>, which is a multi-sig escrow address <a href="https://bitcointalk.org/index.php?topic=279249.msg2983911#msg2983911" rel="noreferrer">created</a> to hold the bounty for the development of <a href="https://bitcointalk.org/index.php?topic=279249" rel="noreferrer">CoinJoin</a>. This is both the first address I observed that doesn't start with <code>1</code>, and the first multi-sig address that I've seen in the wild.</p>

<p>Are there other possible prefixes? What characterizes the different prefixes? (E.g. are all addresses that start with a <code>3</code> multisig addresses? Are there multisig addresses that do not start with a <code>3</code>?)</p>

<address><multi-signature>
What are the different prefixes of Bitcoin addresses?
ripper234
# What are the different prefixes of Bitcoin addresses?

(Asked by: username_0 on 2013-09-07)

Until today, I thought all addresses must start with `1`.

Well, behold [3M8XGFBKwkf7miBzpkU3x2DoWwAVrD1mhk](https://blockchain.info/address/3M8XGFBKwkf7miBzpkU3x2DoWwAVrD1mhk), which is a multi-sig escrow address [created](https://bitcointalk.org/index.php?topic=279249.msg2983911#msg2983911) to hold the bounty for the development of [CoinJoin](https://bitcointalk.org/index.php?topic=279249). This is both the first address I observed that doesn't start with `1`, and the first multi-sig address that I've seen in the wild.

Are there other possible prefixes? What characterizes the different prefixes? (E.g. are all addresses that start with a `3` multisig addresses? Are there multisig addresses that do not start with a `3`?)

**Tags:** address, multi-signature


---

## 4 answers

### Answer by username_4 on 2013-09-08. Score: 8 | Accepted answer

According to the [glossary](https://github.com/oleganza/CoreBitcoin/blob/master/GLOSSARY.md)
the possible prefixes for bitcoin addresses are 1,3 or 5:

I'm quoting here:

> Address
>
> Bitcoin address is a Base58Check representation of a Hash160 of a
> public key with a version byte 0x00 which maps to a prefix "1".
> Typically represented as text (ex. 1CBtcGivXmHQ8ZqdPgeMfcpQNJrqTrSAcG)
> or as a QR code.
>
> A variant of an address is P2SH address: a hash of a spending script
> with a version byte 0x05 which maps to a prefix "3" (ex.
> 3NukJ6fYZJ5Kk8bPjycAnruZkE5Q7UW7i8).
>
> Another variant of an address is not a hash, but a raw private key
> representation (e.g.
> 5KQntKuhYWSRXNqp2yhdXzjekYAR7US3MT1715Mbv5CyUKV6hVe). It is rarely
> used, only for importing/exporting private keys or printing them on
> paper wallets.


---

### Answer by username_1 on 2013-09-07. Score: 3

1 and 3 are currently the only defined prefixes for an base58 encoded address.

1 is most common and denotes a simple "pay-to-PubKey" transaction. This transaction shows an actual recipient address.

3 indicates a "pay-to-script-hash" address that contains a hash (one way fingerprint) of a script that can be used for multiple things including address obfuscation and multi-signature requirements. This script is required to be a valid bitcoin transaction script, but the full script behind the scenes is not public, just the hash.

More information here:
<https://en.bitcoin.it/wiki/BIP_0016>

More info on the base58 implementation used:
<https://en.bitcoin.it/wiki/Base58Check_encoding>


---

### Answer by username_2 on 2013-12-20. Score: 2

The odd prefix comes from a different magic byte used to generate this address. 05 in this case for a script address. Magic bytes are used for different purposes, like indicating the network. Bitcoins private key byte is 0x80, or 128. (testnet is 6F, litecoin has 48, giving L..)

You can find a list here: <https://en.bitcoin.it/wiki/List_of_address_prefixes>

Usually they're defined in the chainparams.cpp <https://github.com/bitcoin/bitcoin/blob/2068f089c8b7b90eb4557d3f67ea0f0ed2059a23/src/chainparams.cpp#L129> for bitcoin and related networks, except in really old versions


---

### Answer by username_3 on 2013-09-10. Score: 2

Here is a comprehensive list of key formats: <https://en.bitcoin.it/wiki/List_of_address_prefixes>. Technically, most of these are not addresses, but this seems to be in line with @username_4's answer, which mentions raw private keys.


---

