Blockchain Explained
Your guide to transactions, smart contracts and more
What is a blockchain wallet and account?
Blockchain Accounts
An account in a blockchain serves two primary purposes:
- To represent ownership of an asset or permissions on a blockchain.
- To interact with blockchain applications via smart contracts.
The types of asset that can be associated with an account include cryptocurrencies native to that blockchain, various types of tokens including NFTs, or specific actions defined via smart contracts such as privileges.
An account is actually an abstraction for a cryptographic key which consists of two parts — a public key and a private key. This approach of having two keys is known as public key cryptography, a widely used cryptographic system.
The account itself is derived from the public key and can be considered a primitive identity for a user of the blockchain. The private key is usually stored within a wallet, which is an abstraction around the public/private key pair compatible with a specific blockchain.
In Ethereum, accounts are defined using hexadecimal strings such as 0x936b14f9eF89f263E775241C394583D5d419c2D2 which is called its address.
The account view in the Chainlens Block Explorer
The types of operations include:
- The sending or receiving of a cryptocurrency such as Ether.
- The deployment of a new smart contract.
- The invocation of a transaction with a smart contract.
- The sending or receiving of a token such as an NFT.
The limits of what can be achieved by accounts are defined by what is possible in smart contracts. For example, some smart contracts provide specific permissions to accounts to manage them or allocate assets that they control. The specifics are defined in the code of a smart contract.
Smart contracts themselves also have an address, which is how they are identified on a blockchain. More information on this can be found in What are smart contracts?.
Longer term it’s likely that addresses will be replaced by human-readable strings, in a similar vein to how websites are identified using a URL such as www.web3labs.com instead of its network address (known as an IP address) which looks like 199.60.103.31.
There are a number of initiatives providing this functionality for different blockchain networks. The most prominent is the Ethereum Name Service (ENS) project. This allows an individual to take a name such as csvensson.eth and map it to the Ethereum address 0x2e11e3b40ca0c4aba93a2cd7c9046394b8dd7501.
Longer-term, these hexadecimal addresses will be replaced by decentralized naming services. However, this will likely take a few more years to become commonplace; meanwhile, addresses are likely to remain in their current format for many users.
Wallets in Web3
A wallet is an abstraction for an account. Wallets typically contain one or more accounts, on one or sometimes multiple blockchain networks. Two of the best-known web3 wallets are Metamask which is a software wallet that runs in your browser or phone, and the Ledger Nano which is a physical device known as a hardware wallet.
The types of interactions that you will perform with a wallet are the same as those operations listed above. The wallet is used by a user to approve the operation which involves cryptographically signing a payload that defines the specific operation we want to undertake on the blockchain network.
Summary
An account is used to hold digital assets such as cryptocurrency and tokens on a blockchain. It can also be used to interact with smart contracts on a blockchain.
An account has an address which is a hexadecimal string. There are decentralized naming services emerging, such as the Ethereum Naming Service (ENS) project, which replaces these strings with human-readable text, but widespread implementation will take time.
There are a number of different operations an account can perform on a blockchain:
Wallets are an abstraction for storing accounts. They can be implemented purely as software, or maybe as physical devices.