Denne siden er kun til informasjonsformål. Enkelte tjenester og funksjoner er kanskje ikke tilgjengelige i din jurisdiksjon.

What is offchain?

Offchain describes transactions that are not processed and recorded one by one by the nodes of a given blockchain, but are completed in a system outside that chain; some approaches later submit the results or transaction data back to that chain. Records written to a blockchain and jointly verified and stored by the nodes in its network are called onchain records. Offchain records, by contrast, are kept by systems outside the chain, such as a trading platform, the two parties to a transaction, or the rollups described below.

"Offchain" is always relative to a particular chain. A sidechain, for example, is a separately operated blockchain connected to Ethereum mainnet through a cross-chain bridge. Transactions on a sidechain are offchain relative to Ethereum, yet they are onchain records on the sidechain's own ledger. A sidechain has its own validators and consensus rules, its security does not come from Ethereum, and moving assets between the two chains also requires trusting the bridge. So when you say "offchain," first make clear which chain you mean.

Offchain transactions are recorded in three places

Common offchain transactions are recorded in three places: a trading platform's own ledger, a channel between the two parties to a transaction, and rollups, which execute transactions offchain and then submit the data onchain. All three reduce the number of transactions that must be written to the blockchain, but they differ in how offchain records make their way back onchain.

A trading platform's internal ledger

After a user deposits crypto assets with a trading platform, the platform records each account's balance in its own system. When users buy, sell, or transfer assets to one another within the platform, the platform only needs to update these account records instead of sending a transaction to the blockchain each time. On OKX, withdrawals come in two kinds: an onchain withdrawal moves assets over the blockchain network to an external wallet or another platform and requires a network fee set by the blockchain; a withdrawal to an OKX user is an internal transfer within the platform that arrives in real time, carries no fee, and does not go through blockchain confirmation. This feature is not available in every region; the OKX help page is the authoritative reference.

The platform ledger connects with the chain at only two moments: a deposit from an external address is an onchain transaction the user sends to a platform address, and an onchain withdrawal is an onchain transaction the platform sends from its own address to the address the user entered. Between these two onchain transactions, the account balance is the platform's own bookkeeping record for the user. Users cannot see these internal changes on a block explorer, and whether a balance can be withdrawn depends on whether the platform holds sufficient assets and continues to operate normally; see crypto custody for more.

Channels between the two parties

A payment channel lets two people first lock assets into a contract on the blockchain, or into a multisignature address whose funds can be moved only with both of their signatures. They then exchange balance updates signed by both of them offchain, as many times as needed, and finally write only the result back onchain. Bitcoin's Lightning Network and state channels on Ethereum both follow this approach.

Suppose Alice and Bob each lock 0.5 bitcoin (BTC) to open a channel, then pay each other 10 times, and the last balance they have both signed is Alice 0.3 BTC and Bob 0.7 BTC. If they agree to close the channel, only two transactions appear onchain: the opening and the closing. At closing, the chain's rules split the 1 BTC between them according to the final balance (excluding onchain fees). The 10 payments in between are kept only by the two parties.

If one party tries to close the channel with an old balance, the other can contest it onchain within a set period. On Ethereum, the state channel contract adopts the more recent signed state and can confiscate the funds the cheating party locked in the contract; in the design described in the Lightning Network paper, the party that follows the rules broadcasts a penalty transaction and takes all the funds in the channel. This protection requires the user, or a service they delegate, to watch the chain within that period.

Rollups: offchain execution, onchain data

This article uses Ethereum as the example. Rollups on Ethereum execute transactions outside mainnet. The node that processes transactions and submits batches is called the operator: it bundles a large number of transactions and publishes the transaction data, or enough data to reconstruct the state, to Ethereum, where a contract records the rollup's state and the assets users have deposited. Relative to Ethereum mainnet, these transactions are executed offchain, yet their data returns onchain; on the rollup's own ledger, they are onchain records.

Contracts on Ethereum confirm these results in one of two ways. An optimistic rollup presumes that the bundled results are correct: during a challenge period, anyone can submit a fraud proof to overturn an incorrect result, which requires at least one honest node to execute the transactions and raise a challenge when it finds an error. A zero-knowledge rollup instead attaches to each batch a cryptographic proof that the computation is correct, called a validity proof, and the contract updates the state only after the proof passes its check. Because the data is published on Ethereum, users can still act on the onchain data if the operator goes offline: in an optimistic rollup, for example, other nodes can use the data to recover the latest state and keep processing transactions, and users can use it to prove their balances and withdraw their assets. A specific rollup's contracts, operator, and proof mechanism can still fail, and publishing data to Ethereum does not make those risks disappear.

How trading platform ledgers, channels and rollups differ

The table below compares them on four points: who keeps the records, when they return onchain, what is relied on in a dispute, and what users need to do:

Trading platform ledger Payment/state channel Rollup
Who keeps the offchain records The trading platform The two channel parties The rollup operator, with data published to Ethereum
When records return onchain On deposits from external addresses or onchain withdrawals When the channel opens or closes, or when a dispute arises After each batch of transactions is bundled
What is relied on in a dispute The platform's operations, asset safekeeping, and user agreement Onchain rules settle disputes based on records signed by both parties Contracts on Ethereum check fraud proofs or validity proofs
What users need to do Trust that the platform can pay out the recorded balance Keep the signed records and watch the chain within the deadline Rely on onchain data and the proof mechanism, as well as the specific rollup's implementation

Approaches that rely on onchain rules also involve waiting and operating costs. For example, withdrawing from an optimistic rollup back to Ethereum generally means waiting for a challenge period of about seven days to end, and channel users who delegate a dedicated "watchtower" service to monitor the chain for them add to their costs.

Benefits and trade-offs of offchain transactions

The benefit of moving transactions offchain is straightforward: transactions on chains such as Ethereum and Bitcoin must be processed by the nodes in the network and involve network fees, so moving large numbers of transactions offchain reduces the work mainnet does transaction by transaction and spreads out onchain fees, although actual speed and cost still depend on the service's design and usage. The trade-off is that users must place additional trust in some party or take on additional operating requirements; the comparison table above shows what each approach requires. When assessing an offchain service, start by asking who keeps the records, when they return onchain, and what rules settle disagreements.

FAQ

Are offchain transactions always cheaper than onchain transactions?

Not necessarily. Offchain processing avoids the fee of submitting each transaction to mainnet, but there may still be service fees. Opening and closing a channel, a rollup publishing data to Ethereum, and onchain withdrawals from a platform all still require onchain fees; those fees are simply shared across many transactions or incurred at only a few points in time.

Can offchain records be changed?

It depends on who keeps them. A platform ledger is maintained by the platform; a channel balance can be updated only with both parties' signatures. Neither platform ledgers nor channel balances are protected by the blockchain network's consensus. Once a rollup's transaction data is published to Ethereum, overturning it would require overturning the records on Ethereum.

Learn more about onchain, blockchain, blockchain nodes, smart contracts, gas fees, crypto custody, block explorers, and cross-chain, or return to the cryptocurrency glossary.

References

Ansvarsfraskrivelse
Dette innholdet leveres kun til informasjonsformål og kan omhandle produkter som ikke er tilgjengelige i din region. Det er ikke ment å utgjøre (i) investeringsrådgivning eller en investeringsanbefaling, (ii) et tilbud eller en oppfordring til å kjøpe, selge eller hold krypto/digitale aktiva, eller (iii) finansiell, regnskapsmessig, juridisk eller skattemessig rådgivning. Holding av krypto/digitale aktiva, inkludert stablecoins, innebærer en høy grad av risiko og kan svinge betydelig. Du bør nøye vurdere om trading eller holding av krypto/digitale aktiva er egnet for deg i lys av din økonomiske situasjon. Ta kontakt med din juridiske/skattemessige/investeringsrådgiver for spørsmål om dine spesifikke omstendigheter. Informasjon (inkludert markedsdata og statistisk informasjon, om noen) som fremgår av dette innlegget er kun for generelle informasjonsformål. Selv om det er utvist all rimelig aktsomhet ved utarbeidelsen av disse dataene og grafene, påtas det intet ansvar for eventuelle faktafeil eller utelatelser som er kommet til uttrykk her.

Digitale aktiva er utsatt for volatilitet og er ikke forsikret. Ikke finansiell/investeringsrådgivning. Ikke alle produkter og tjenester tilbys i alle regioner. Unntak og vilkår og betingelser gjelder.

© 2026 OKX. Denne artikkelen kan gjengis eller distribueres i sin helhet, eller utdrag på 100 ord eller mindre av denne artikkelen kan brukes, forutsatt at slik bruk er ikke-kommersiell. Enhver gjengivelse eller distribusjon av hele artikkelen må også tydelig angi: «Denne artikkelen er © 2026 OKX og brukes med tillatelse.» Tillatte utdrag må sitere navnet på artikkelen og inkludere kildehenvisning, for eksempel «Artikkelnavn, [forfatternavn hvis aktuelt], © 2026 OKX.» Noe innhold kan være generert eller assistert av verktøy for kunstig intelligens (AI). Ingen bearbeidelser eller annen bruk av denne artikkelen er tillatt.

Relaterte artikler

Se mer
crypto-glossary-cover-v5.contentful

Crypto Glossary A–Z

Explore key crypto, blockchain, and trading terms through concise definitions, organized alphabetically for quick reference. [A](#a) · [B](#b) · [C](#c) · [D](#d) · [E](#e) · [F](#f) · [G](#g) · [H](#
3. des. 2026
12-03-glossary-thumnail/zero-knowledge-rollup

What is a ZK rollup?

**A zero-knowledge rollup (ZK rollup) is a type of [rollup](/learn/what-is-a-rollup): it hands the results of a batch of transactions to the main chain together with a proof, and the main chain accept
3. des. 2026
12-03-glossary-thumnail/zero-knowledge-proof

What is a zero-knowledge proof?

**A zero-knowledge proof (ZKP) lets someone convince another party that a statement is true without revealing any information beyond the statement itself.** The party that submits the proof is called
3. des. 2026
12-03-glossary-thumnail/validator

What is a validator?

**A validator is a participant in a [proof-of-stake](/learn/what-is-proof-of-stake) blockchain that proposes new blocks and votes on other blocks.** It must first [stake](/learn/what-is-staking) the a
3. des. 2026
12-03-glossary-thumnail/unspent-transaction-output-utxo

What is an unspent transaction output (UTXO)?

**An unspent transaction output (UTXO) is an amount of bitcoin (BTC) that a transaction has paid to someone and that has not yet been spent again; each record states the amount and the conditions for
3. des. 2026
what-is-blockchain

What is transactions per second (TPS)?

**Transactions per second (TPS) is a figure that measures how many transactions a [blockchain](/learn/what-is-a-blockchain) can process, or actually processes, each second. It is also called throughpu
3. des. 2026
Se mer