Public-key cryptography (also known as public-key encryption and asymmetric encryption) is a system for data encryption which involves a public key and an associated private key.
Public-key cryptography enables two parties to communicate securely with each other online over an insecure network. The sender first encrypts the data they wish to communicate and then sends it to the digital address of the intended recipient. Once received, the recipient uses their private key to decrypt the data. In the meantime, public-key cryptography ensures that the data being encrypted won't be altered unless the encryption is broken by an attacker, and that there is a digital record of the data being sent which can be referenced at a later date.
Bitcoin and other cryptocurrencies use public-key cryptography in the creation of new digital currency wallets and for validating transactions. The public key is also known as the wallet address because - after being converted into a hash by a cryptographic hash function - it is used to send and receive cryptocurrencies with other wallets.
The private key is meant to be a secret known only by the wallet's owner, as anybody who knows the private key and its corresponding public key can access the funds inside a wallet. The private key is used to create a digital signature for cryptocurrency transactions, ensuring that the transactions are valid and can be verified in the future.
Public-key encryption is also used for secure network connections (HTTPS websites) via SSL certificates, as well as to securely send emails via the PGP protocol.