Cross-Chain Interoperability Protocol (CCIP) | Chainlink
A secure interoperability protocol for
enabling token transfers across blockchains
sending cross-chain messages
building cross-chain applications
enabling cross-chain real-world assets
scaling cross-chain ecosystems
connecting private and public blockchains
enabling token transfers across blockchains
Start building with Chainlink CCIP
Securely send messages, transfer tokens, and initiate actions across blockchains.
// The message to send cross-chain with CCIP
struct EVM2AnyMessage {
bytes receiver; // Receiver at destination
bytes data; // Arbitrary data payload
EVMTokenAmount[] tokenAmounts; // ERC20 tokens and amounts
address feeToken; // Token to pay fees with
bytes extraArgs; // Optional parameters
}
// Sending a message to any destination chain with CCIP
function ccipSend(
uint64 destinationChainSelector,
EVM2AnyMessage calldata message)
external
payable
returns (bytes32 messageId);
// Set the tokens and amounts to transfer
Client.EVMTokenAmount[] memory tokenAmounts = new Client.EVMTokenAmount[](1);
Client.EVMTokenAmount memory tokenAmount = Client.EVMTokenAmount({
token: _addressToken,
amount: _amount
});
tokenAmounts[0] = tokenAmount;
// Create an EVM2AnyMessage struct in memory to send via CCIP
Client.EVM2AnyMessage memory message = Client.EVM2AnyMessage({
receiver: abi.encode(_receiver), // Receiver (EOA) at destination
data: "", // No data to send
tokenAmounts: tokenAmounts, // ERC20 tokens and amounts
extraArgs: Client._argsToBytes( // Optional parameters
Client.EVMExtraArgsV1({
gasLimit: 0, // gasLimit = 0 because EOA
strict: false}) // No strict sequencing
),
feeToken: address(_addressLink) // Setting feeToken to LINK
});
// approve the Router to spend tokens on sender contract's behalf.
IERC20(addressToken).approve(address(router), _amount);
// Send the message through the router and store the returned message ID
bytes32 messageId = router.ccipSend(
destinationChainSelector,
message
);
// Create an EVM2AnyMessage struct in memory to send via CCIP
Client.EVM2AnyMessage memory message = Client.EVM2AnyMessage({
receiver: abi.encode(_receiver), // Receiver contract at destination
data: abi.encode("Hello world!"), // Send "Hello world!"
tokenAmounts: new Client.EVMTokenAmount[](0), // No tokens to be sent
extraArgs: "", // Use default values
feeToken: address(_addressLink) // Setting feeToken to LINK
});
// Send the message through the router and store the returned message ID
bytes32 messageId = router.ccipSend(
destinationChainSelector,
message
);
CCIP is the only interoperability protocol with level-5 security
Deploy a Cross-Chain Token (CCT) in minutes
The Cross-Chain Token (CCT) standard
A secure framework that enables token developers to integrate new and existing tokens with CCIP in a self-serve manner in minutes. CCTs are cross-chain native tokens secured by CCIP. CCTs support self-serve deployments, full control and ownership for developers, enhanced programmability, and zero-slippage transfers—all backed by CCIP’s industry-standard defense-in-depth security.
CCIP Token Manager
A new intuitive front-end web interface for token developers to seamlessly register, configure, and manage CCTs and token pools across multiple blockchain networks, including no-code, guided token deployments.
Developer Control and Flexibility
Token developers retain full ownership of their token contracts, CCIP token pools, and customized implementation logic, including rate limits across all blockchains. This ensures complete autonomy and flexibility when managing CCT deployments, without requiring vendor lock-in, hard-coded functions, or external dependencies that may limit future optionality or add risks to security.
Introducing the Risk Management Network
An independent network of nodes that enhances CCIP security by acting as a secondary validation service and detecting and halting anomalous activity.
Featured CCIP-Powered Bridges
Future-proof your Web3 strategy
All code examples on this site are illustrative and are provided on an “as is” basis without any representations, warranties, covenants, or conditions of any kind. Use of these code snippets is governed by our Terms of Service found at chain.link/terms.