In this track: Meet smart contracts
beginner · 3 MIN READ

What is an oracle?

A mechanism for supplying information a contract cannot directly observe.

LET’S PICTURE IT

A classroom judge can record a sports result supplied by a reporter. The rule for trusting the reporter is part of the system.

SEE IT FOR YOURSELF
Receive, check and share across independent nodesStep 1 / 4
Receive, check and share across independent nodesIncoming dataCandidate instructionNot yet trustedNode AReceives the messageApplies local checksEach participant has a local view of incoming informationNode A checksAuthorizationProtocol validityValid candidateEligible for next stepsNot a finality promiseApplication safety is a different claim from protocol validityNode AShares checked dataNode BChecks for itselfNode CChecks for itselfNode ARules checked✓Node BRules checked✓Node CRules checked✓Agreement on history adds the consensus mechanism

A node receives a proposed transaction or block-related message. Receipt is not the same as accepting its claims.

Animated local teaching model. No wallet, RPC or live blockchain data. Some labels and hashes are abbreviated for readability.

The outside-world gap

A contract can calculate from its inputs and chain context. It cannot automatically know an offchain event, market quote or physical delivery status. An oracle design brings relevant information into a form the contract can use.

Different designs make different assumptions

One design may trust a specific signer; another may aggregate several reports or use proofs and additional mechanisms. A label such as oracle does not specify freshness, availability or resistance to manipulation by itself.

Correct code can still use a bad input

A lending calculation can follow its arithmetic perfectly while using a stale or manipulated price. Applications need rules for checking the conditions under which a supplied input is acceptable.

Separate the question being verified

A contract might verify who signed a report without proving the report matches reality. Read signatures and contract limits to distinguish authorization, computation and truth about external events.

QUICK CHECK · NO PRESSURE

Does verifying a report’s signature alone prove the report is factually true?

Your progress stays in this browser.
Keep exploring the original referenceethereum.org ↗

Original explanations by EtherTools. Examples are educational and source-linked; this site is independent of the Ethereum Foundation. Our approach.