Skip to main content

What Is a Private Key?

What Is a Private Key?​

A private key is a long secret number that controls one blockchain address. Whoever has it can sign transactions from that address and move everything it holds. Your address is derived from the private key and is safe to share; the private key itself must stay secret.

Private keys are usually shown as a string of letters and numbers. The format depends on the network:

NetworkTypical formatExample start
Ethereum and other EVM networks64 hexadecimal characters, sometimes with 0x0x4c08…
SolanaBase58 string (often 87–88 characters) or hexadecimal5Kd3…
StellarSecret key starting with S (56 characters) or hexadecimalSB2X…
NEARed25519: followed by a Base58 keyed25519:3n…
Suisuiprivkey1… (Bech32), or hexadecimalsuiprivkey1q…
Aptosed25519-priv-0x…, or hexadecimaled25519-priv-0x9d…
Most other networksHexadecimal9f1a…

Solana Private Key Ethereum Private Key

Private Key vs Secret Phrase​

Private keySecret Phrase
ControlsOne address on one networkEvery address in a Multi-Coin wallet, on every network
Looks likeA long string of characters12 or 24 ordinary words
CreatedDerived from a Secret Phrase, or generated on its ownWhen you create a wallet
RestoresOnly that one addressThe whole wallet

A Gem Wallet Multi-Coin wallet is created from a Secret Phrase, and each network's private key is derived from it. Backing up the Secret Phrase backs up all of those keys at once, so you normally never need to handle a private key.

Private Key Wallets in Gem Wallet​

Gem Wallet can create a single-network wallet from a private key you already have, for example one exported from another wallet.

Supported: Ethereum and other EVM networks, Solana, TON, TRON, Sui, Aptos, NEAR, Stellar, XRP Ledger, Algorand, Polkadot, Cosmos-based networks, and most other networks in Gem Wallet.

Not supported: Bitcoin, Litecoin, Bitcoin Cash, Dogecoin, Dash, Zcash, and Cardano. For these, import the wallet's Secret Phrase instead.

A private key wallet holds one address on one network. To use more networks, create or import a Multi-Coin wallet with a Secret Phrase.

How to Import a Private Key​

  1. Open Gem Wallet and select Import an Existing Wallet. If you already have a wallet, open Settings > Wallets and select Import an Existing Wallet.
  2. Choose the network the key belongs to. Private keys are imported per network, not as Multi-Coin.
  3. Select Private Key.
  4. Type, paste, or scan the key, then select Import.

If you paste the key, Gem Wallet clears it from the clipboard after importing. If Gem Wallet says the key is invalid, check that you chose the right network and that the key is complete, with no extra spaces or characters.

See Restore Gem Wallet for importing with a Secret Phrase.

How to View a Private Key in Gem Wallet​

Gem Wallet can show a private key in two places:

  • A wallet created from a Secret Phrase: open the wallet in Settings > Wallets and select Advanced > Show Private Key, then choose the account.
  • A wallet you imported with a private key: open the wallet in Settings > Wallets and select Backup > Show Private Key.

For step-by-step instructions with screenshots, and how to check an exported key, see How to Export a Private Key from Gem Wallet.

If your wallet was created from a Secret Phrase, the phrase already backs up all of its accounts, so export a key only when you need one account in another wallet. Keys are exported in these formats:

NetworkExported as
Ethereum and other EVM networksHexadecimal. The same key controls your account on every EVM network. When a key also controls other accounts in your wallet, on EVM or other networks such as Cosmos-based ones, Gem Wallet names those networks under the key
SolanaBase58 keypair (seed and public key), the format other Solana wallets import
NEARed25519: followed by a Base58 keypair
Suisuiprivkey1…, Sui's standard format
Aptosed25519-priv-0x…, Aptos's standard format
StellarSecret key starting with S
Most other networksHexadecimal

Before Gem Wallet 2.114.96, Sui, Aptos, and Stellar keys were exported as plain hexadecimal. Those keys still import into Gem Wallet as the same account.

Bitcoin-family networks (Bitcoin, Litecoin, Bitcoin Cash, Dogecoin, and others) and Cardano aren't listed, because other wallets can't import their raw keys. To move those accounts, import your Secret Phrase instead, or see How to Get Your Private Key from a 12-Word Recovery Phrase.

Keep Your Private Key Safe​

warning

Anyone who has your private key can take everything in that address. Gem Wallet can't recover a lost key or reverse a transaction made with a stolen one.

  • Never share it. Gem Wallet support, exchanges, and swap providers will never ask for your private key.
  • Never type it into a website or a form you reached from a link, an email, or a direct message.
  • Store it offline, written down or in a secure password manager you control, not in screenshots, cloud notes, or chat messages.
  • A private key wallet's only backup is the key itself. If you delete the wallet or lose your device without a copy, the funds can't be recovered.

If you think someone has seen your private key, move the funds to a new wallet right away. See What to Do If Your Crypto Wallet Is Compromised?.