Universal Smart Contracts

ZetaChain’s Universal Smart Contracts lets you access and manage assets, data, and liquidity on any blockchain — all from a single place.

Start Building →

How do Universal Smart Contracts work?

With our EVM module and the new ZRC-20 Standard, developers can create and deploy Universal Smart Contracts that control native assets and data on any chain. These contracts can be called from external chains and generate outbound transactions on external chains including even the Bitcoin network.

Build Universal dApps →

contract YourContract is zContract {
  function onCrossChainCall(
    zContext calldata context,
    address zrc20,
    uint256 amount,
    bytes calldata message
  ) external virtual override {
    bytes32 recipient = abi.decode(message, (bytes32));

    (, uint256 gasFee) = IZRC20(zrc20).withdrawGasFee();

    IZRC20(zrc20).approve(zrc20, gasFee);
    IZRC20(zrc20).withdraw(
      abi.encodePacked(recipient),
      amount - gasFee
    );
  }
}

Built for an unparalleled developer experience

Deploy Once, Access All Chains

Fewer Transactions, Fewer Fees

Safer, Better User Experience

Manage a single contract for all chains instead of one contract for each supported chain. Experience the simplicity of building on Ethereum with access to assets on any chain, even non-smart contract chains like Bitcoin.

Complex contract logic on ZetaChain can orchestrate assets across all connected external chains through simple transfers and single transactions, minimizing total gas expenditure and slippage for users.

Transaction logic occurs atomically in our smart contracts, resulting in lower slippage, reduced attack surface, and less susceptibility to race conditions. Experience truly one-step transactions (and fees), even when operating across chains.

Working with Universal Smart Contracts

Explore Universal Apps

Explore what others are building as Universal apps on ZetaChain.

Have questions?
Check out FAQ or chat with an expert.