# Crosschain Swap

Crosschain Swaps in Onchain Toolkit, powered by LayerZero, enable secure and seamless asset transfers across blockchain networks. Here’s how to get started:

**Step 1: Connect Your Wallet**

<figure><img src="https://2529480011-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5cTyOTzx3V99hovHgxrf%2Fuploads%2Fht3Spon0U1EynjKW5DO8%2Fimage.png?alt=media&#x26;token=e29f36af-3c83-4ab1-9870-b6b3c80c82a8" alt=""><figcaption></figcaption></figure>

Open the Onchain Toolkit platform.

Click the Connect Wallet button at the top right of the interface.

Select your preferred wallet (e.g., MetaMask, WalletConnect) and authorize the connection.

Ensure that your wallet is configured for the blockchain network you want to swap from.



**Step 2: Navigate to Crosschain Swaps**

<figure><img src="https://2529480011-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5cTyOTzx3V99hovHgxrf%2Fuploads%2FxDtc33gGGZfbAdtrc8lO%2Fimage.png?alt=media&#x26;token=32a1f103-fb3c-45cd-8da7-83564d5cd5d9" alt=""><figcaption></figcaption></figure>

On the left-hand sidebar, click on Crosschain Swaps to open the swaps interface.

You’ll see fields to select the source blockchain, destination blockchain, and the asset you want to swap.

**Step 3: Choose Your Networks and Asset**

<figure><img src="https://2529480011-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5cTyOTzx3V99hovHgxrf%2Fuploads%2FZMN0vp4X0ufe8toF71aW%2Fimage.png?alt=media&#x26;token=63fcc4fd-1b84-4853-b020-fc5839512fd4" alt=""><figcaption></figcaption></figure>

Source Network: Select the blockchain where your assets are currently located. (Example: Ethereum, Binance Smart Chain, or Polygon)

Destination Network: Choose the blockchain where you want to send your assets.

Asset Selection: Pick the token or cryptocurrency you wish to swap. Make sure the asset is supported on both the source and destination networks.

<figure><img src="https://2529480011-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5cTyOTzx3V99hovHgxrf%2Fuploads%2F4Ly6HsmaRanlLnjThsbF%2Fimage.png?alt=media&#x26;token=434c6e28-2bc4-4646-9190-3cf728dc7952" alt=""><figcaption></figcaption></figure>



**Step 5: Preview, Confirm and Approve the Swap**

<figure><img src="https://2529480011-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5cTyOTzx3V99hovHgxrf%2Fuploads%2Ft7OlIU9zJWS47jstVSYb%2Fimage.png?alt=media&#x26;token=7887636e-55c3-42a5-b1b1-4b54cf297667" alt=""><figcaption></figcaption></figure>

Once you have click preview, you can choose from the selected provider.

Click Approve to authorize the transaction in your connected wallet.

Once approved, click Swap to initiate the crosschain transfer.

A confirmation window will appear with the transaction details. Review them carefully before confirming.

<figure><img src="https://2529480011-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5cTyOTzx3V99hovHgxrf%2Fuploads%2FRXMJ8DFvEcCnujwgvf0V%2Fimage.png?alt=media&#x26;token=a29d54f1-4219-41ef-b760-ac3327757836" alt=""><figcaption></figcaption></figure>



**Step 6: Wait for Confirmation**

<figure><img src="https://2529480011-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5cTyOTzx3V99hovHgxrf%2Fuploads%2FRO1mQ6OAUb1geAj71IR4%2Fimage.png?alt=media&#x26;token=ba8983fd-1566-4144-9f35-27a7f125a165" alt=""><figcaption></figcaption></figure>

The swap process will take a few minutes as LayerZero technology securely transfers your assets across networks.

You can monitor the progress of your transaction directly on the platform or by checking the transaction ID in a blockchain explorer.

**Step 7: Verify Your Balance**

Once the swap is complete, your assets will appear in your wallet on the destination blockchain.

Open your wallet and ensure the token balance reflects the swapped amount.

**Best Practices for Crosschain Swaps**

Check Supported Assets: Ensure the asset and blockchain combination is supported by Onchain Toolkit.

Verify Fees: Review transaction fees before confirming the swap to avoid surprises.

Ensure Sufficient Gas: Make sure you have enough native cryptocurrency (e.g., ETH, BNB) for gas fees on both the source and destination networks.

Use a Reliable Wallet: Ensure your wallet is up to date and compatible with LayerZero-powered swaps.

**Why Use Crosschain Swaps?**

* Trustless Transactions: LayerZero ensures secure, decentralized swaps without intermediaries.
* Enhanced Liquidity: Access fragmented markets and broaden your investment options.
* Efficient and Fast: Seamless asset transfers without relying on traditional centralized exchanges.

Onchain Toolkit makes crosschain swaps straightforward and efficient, empowering users to navigate decentralized finance with ease. Whether you're optimizing your portfolio or exploring new markets, these swaps unlock the full potential of the blockchain ecosystem!
