Convert a raw 32-byte hex private key to Wallet Import Format (WIF) and back. Supports mainnet/testnet, compressed/uncompressed public key flag. Offline.
Every Bitcoin private key is a 32-byte number. Most wallet software does not show you that number directly: it encodes it as a Wallet Import Format (WIF) string first, a Base58Check-encoded form that looks like KwDiBf89QgGbjEhKnhXJuH7LrciVrZi3qYjgd9M7rFU73sVHnoWn and is easier to copy, type, and verify than 64 raw hex digits. This tool converts in both directions.
Switch to Hex → WIF to encode a 64-character hex private key, choose mainnet or testnet and whether the wallet derives a compressed or uncompressed public key. Switch to WIF → Hex to decode a WIF string back to the raw key, with a full checksum verification and a breakdown of every field.
0x80 for mainnet, 0xEF for testnet. Mainnet compressed keys start with K or L, mainnet uncompressed keys start with 5, and testnet compressed keys start with c.0x01 appended after the key when the wallet uses a compressed 33-byte public key (SEC format, prefix 02 or 03). Omitted when the wallet uses the older uncompressed 65-byte form (prefix 04). The same private key produces two different Bitcoin addresses depending on which form is used, and this flag records which one.Click the Mainnet Compressed chip on the WIF → Hex tab to load: KwDiBf89QgGbjEhKnhXJuH7LrciVrZi3qYjgd9M7rFU73sVHnoWn. The tool decodes it to hex key 0c28fca386c7a227600b2fe50b7cae11ec86d3bf1fbe471be89827e19d72aa1d, reports mainnet · compressed, and shows both the given and computed checksum bytes side-by-side. Click Send to Hex → WIF panel to verify round-trip and the encoder re-derives the same WIF from those bytes, confirming no information was lost in either direction.
Load a test vector
64 / 64 characters
Network
Public key
The test vectors above are taken from the Bitcoin Wiki WIF page and BIP-32 test vectors — they are not real keys protecting any funds. Never paste a private key that controls real funds into any website. All computation here runs entirely in your browser tab; nothing is uploaded.