<p>GPG keys are usually RSA keys.
RSA keys are based on the difficulty of the factorization. Keys are usually 2048 or 4098 bits.</p>

<p>Bitcoin uses ECDSA (Elliptic Curve Digital Signature Algorithm), where keys are usually smaller. Bitcoin uses the curve secp256k1 where keys are 256bits.</p>

<p>Roughly, an RSA key with 2048 bits offer similar security then a 256 bit ECDSA key.
Both offer more or less 128bit of "symmetric" security.</p>

<p>With newer versions of GPG you can also generate and use EC keys (nist-P, ed25519 or secp256k1)</p>

CC BY-SA 3.0
2017-12-20T10:40:03.240Z
PGP keys can also be DSA/ElGamal which are about the same size as RSA. In addition a PGP 'secret' (private) key packet actually includes both the private _and_ public key values, with the private part encrypted which adds some overhead, plus metadata: at least one userid and usually at least one signature and sometimes other attributes. And a PGP key _block_ (either public or secret=private) usually includes not just one keypair but a 'master' key and one or sometimes more subkey(s). OTOH PGP uses base64 while bitcoin uses base58 which is a tiny bit less space-efficient.
dave_thompson_085
CC BY-SA 3.0
2017-12-20T14:24:20.090Z
Thanks for the help, both of you...The part about a PGP key block containing a bunch of extra data makes a lot of sense. I have some follow-ups though if that's okay:
1) Why does an RSA key need to be 2048 bits to offer similar security compared to a 256-bit ECDSA key?
2) Does the fact that Bitcoin keys are only used for signing whereas a PGP key is used for both signing and encrypting have anything to do with this?
steevven1
CC BY-SA 3.0
2017-12-20T15:52:19.893Z
I propose, that this is a good question for another crypto forum? Bitcoin doesn't use RSA...
pebwindkraft
CC BY-SA 3.0
2017-12-20T06:18:29.087Z
2017-12-20T06:18:29.087Z
Jonas Schnelli
<p>My PGP key takes up a huge, multi-line block of text, but my Bitcoin private key is just a small string. Yet both are considered extremely secure. Why is my PGP private key so long?</p>

<private-key><pgp>
Why is my Bitcoin private key so much shorter than my PGP private key?
steevven1
# Why is my Bitcoin private key so much shorter than my PGP private key?

(Asked by: username_0 on 2017-12-20)

My PGP key takes up a huge, multi-line block of text, but my Bitcoin private key is just a small string. Yet both are considered extremely secure. Why is my PGP private key so long?

**Tags:** private-key, pgp


---

## 1 answers

### Answer by username_1 on 2017-12-20. Score: 3

GPG keys are usually RSA keys.
RSA keys are based on the difficulty of the factorization. Keys are usually 2048 or 4098 bits.

Bitcoin uses ECDSA (Elliptic Curve Digital Signature Algorithm), where keys are usually smaller. Bitcoin uses the curve secp256k1 where keys are 256bits.

Roughly, an RSA key with 2048 bits offer similar security then a 256 bit ECDSA key.
Both offer more or less 128bit of "symmetric" security.

With newer versions of GPG you can also generate and use EC keys (nist-P, ed25519 or secp256k1)

> **Comments:**
> **username_2**: PGP keys can also be DSA/ElGamal which are about the same size as RSA. In addition a PGP 'secret' (private) key packet actually includes both the private _and_ public key values, with the private part encrypted which adds some overhead, plus metadata: at least one userid and usually at least one signature and sometimes other attributes. And a PGP key _block_ (either public or secret=private) usually includes not just one keypair but a 'master' key and one or sometimes more subkey(s). OTOH PGP uses base64 while bitcoin uses base58 which is a tiny bit less space-efficient.  
> **username_0**: Thanks for the help, both of you...The part about a PGP key block containing a bunch of extra data makes a lot of sense. I have some follow-ups though if that's okay: 1) Why does an RSA key need to be 2048 bits to offer similar security compared to a 256-bit ECDSA key? 2) Does the fact that Bitcoin keys are only used for signing whereas a PGP key is used for both signing and encrypting have anything to do with this?  
> **username_3**: I propose, that this is a good question for another crypto forum? Bitcoin doesn't use RSA...  

---

