# EIP-5164:  Cross-Chain Execution

<table data-header-hidden><thead><tr><th width="153"></th><th></th></tr></thead><tbody><tr><td><strong>Initiative Name</strong></td><td>EIP-5164: Cross-Chain Execution</td></tr><tr><td><strong>Organization</strong></td><td>-</td></tr><tr><td><strong>Type</strong></td><td>Standard </td></tr><tr><td><strong>Description</strong></td><td>The specification introduces a cross-chain execution interface for EVM-based blockchains, enabling contracts on one chain to interact with contracts on another through cross-chain messages. It comprises two main components: the "Message Dispatcher" (on the calling side) and the "Message Executor" (on the receiving side). When a message is dispatched, it's relayed from the dispatcher to the executor via a transport layer for execution. This standardization arises from a need for Ethereum protocols to manage state changes across multiple EVM blockchains. While many chains possess bridges to execute Ethereum contracts, these bridges come with varied APIs, leading to custom integrations and inconsistent properties like security and speed. This common specification aims to promote code reusability and consistent bridge implementations. Bridges can couple multiple MessageDispatchers to a MessageExecutor, and users can send messages without knowing the executor's address. Some bridges might necessitate payments in native currency, making the dispatchMessage function payable.</td></tr><tr><td><strong>Ecosystem</strong></td><td>Ethereum</td></tr><tr><td><strong>Public Participants</strong></td><td><p>PoolTogether</p><p>Brendan Asselstine</p><p>Pierrick Turelier</p><p>Chris Whinfrey</p></td></tr><tr><td><strong>Link</strong></td><td><a href="https://eips.ethereum.org/EIPS/eip-5164">https://eips.ethereum.org/EIPS/eip-5164</a> </td></tr></tbody></table>

This specification defines a standardized interface for cross-chain message passing and execution between EVM-based blockchains. The key points are:

* It does not rely on specific bridges or gateways. It aims to define a common standard that various bridge/gateway implementations can adopt.
* There are two main components - MessageDispatcher on the sending chain and MessageExecutor on the receiving chain.
* MessageDispatcher dispatches messages to target chain by emitting events that are picked up by MessageExecutor.
* MessageExecutor receives and executes messages, ensuring each message is processed only once.
* MessageDispatcher returns a unique messageId to track dispatch status.
* MessageExecutor appends message metadata to call data when executing.
* Emits events like MessageDispatched and MessageExecuted to confirm status.
* Defines error handling for failed executions.
* Allows payable messages to cover gas fees.
* Aims to support backwards compatibility with existing bridges/gateways.

This spec aims to standardize cross-chain messaging in a bridge/gateway agnostic way. It focuses on the dispatcher and executor functionality required for message passing between EVM chains. Actual bridge/gateway implementations can build on top of this standard interface.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://qualitax.gitbook.io/interop/industry-initiatives/eip-5164-cross-chain-execution.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
