Library · Crypto, word by word · DeFi
What is a blockchain oracle?
An oracle is a service that brings information from outside a blockchain, such as a coin's price, onto the chain so smart contracts can use it. Blockchains cannot fetch outside data on their own, so lending, trading and insurance contracts rely on oracles.
What it means for you
A contract is only as accurate as the data it reads. If an oracle reports a wrong or manipulated price, a protocol can liquidate positions or let attackers drain funds, and the code will treat it as valid. Check which oracle a protocol uses and whether it depends on a single source.
A common mistake: “A smart contract checks prices on its own.”
In fact: Contracts cannot reach outside data. They act on whatever an oracle last wrote on-chain, and if that value is stale or manipulated, the contract acts on it anyway.
How it works
Every node must reach the same result from the same inputs, so a contract cannot call a website: answers could differ between nodes and break agreement. An oracle instead writes the data on-chain in a transaction. Price feeds usually follow a publish-subscribe pattern, regularly updating a contract that others read; request-response oracles answer a specific query. A single operator is a single point of failure, so decentralized oracles gather values from many nodes and aggregate them, for example by taking the median, with staking rewards and penalties to encourage accurate reporting.
Source: ethereum.org: Oracles · checked 4 October 2026
Related words
Educational content, not financial advice. Written by hand and checked against the source named above. Something wrong? Tell us and we reply within two business days.