How It Works
Once generated, a single deposit address can be reused so long as the origin currency, origin chain, destination currency, and destination chain all remain the same. To enable using a deposit address for your bridge, you will need to set theuseDepositAddress body parameter to true in the quote request.
When using deposit addresses, the user parameter can be any valid address, including the zero address (0x0000000000000000000000000000000000000000). This provides flexibility in how you structure your deposit address requests.
Failures via deposit addresses are extremely rare, but are still possible. If something goes wrong, we will default to manually handling refunds. If you wish to automatically receive refunds on the origin chain, specify the refundTo address. This will mean refunds will automatically be issued on origin in case of any filling failures.
The deposit transaction requires no calldata. You just need to send any value to the address specified in the API request response data. As long as this amount is enough to cover any gas or relay fees, it will be automatically bridged based on the route requested in the initial quote.
When using deposit addresses, there are more relayer gas fees associated with bridges. Typically about
33,000 extra gas is required than regular native bridges, and about 70,000 more for ERC-20 bridges. For very small bridges, we don’t recommend using deposit addresses since so much gas is required.
Once a deposit occurs, the quote will automatically be generated post-deposit to account for gas fluctuation and recompute all fees. This can change the amount received to be different than the quoted value but will always be at least the minimum rate. If the minimum rate cannot be achieved, the deposit amount will be refunded.
All Relay EVM deposit addresses begin and end with the character d (not case-sensitive). This is to help us with reducing the indexing search space.
Supported Currencies
To determine which currencies support deposit addresses on a specific chain, use the chains API endpoint. Each chain’s response includes asolverCurrencies array that contains all currencies available for deposit address bridging on that chain. This method provides the most straightforward way to check deposit address support without requiring additional queries.
Edge Cases
We have automatic handling for common edge cases that can occur when using deposit addresses:- Depositing to the Wrong Chain — For example, if the bridge request requires a deposit on Base but the funds are deposited on Optimism, this amount is bridged to the destination chain originally requested as long as its enough to cover the fees and gas associated with the bridge. Please note that this will mean a new quote will be generated in-flight. NOTE: This is only supported for relay supported cross-chain currencies, see limitations.
- Extra Funds are Received — If the user deposits more funds than what is quoted, the quote will be regenerated to account for this surplus amount and the bridge will still be filled.
- Less Funds are Received — If the user deposits less funds than what is quoted, a new quote will be generated to account for the lower amount, and the bridge will be filled.
Limitations
- Calldata execution on destination is not allowed.
- Only exact input bridging is allowed. Specifying exact output will not work.
- When non-supported currency or NFTs are sent to the deposit address, we currently do not support recovering of those assets.
Debugging
When looking up the status of a bridge or fetching the request data, please use therequestId and our Get Execution Status API.
The transaction hash of the deposit transaction cannot be used to lookup the status of the bridge for deposit address bridges.
To help with debugging transactions, make sure to store the requestId along with other data (quotes, transactions,
bridges, etc). The requestId is unique to Relay’s database and will be returned with the quote.
Example Request
You will find an example below of sending 0.01 ETH from Base to Optimism.cURL
useDepositAddressmust be set totrueusercan be any valid address, including the zero addressrefundTocan be optionally set whenuseDepositAddressis being used. This is the address that refunds will be sent to in case of an issue. If not specified then manual refund is required.
Example Response
Common Use Cases
Deposit addresses are particularly useful in the following scenarios:- CEX-to-DeFi Bridging — When users are already performing a withdrawal from a centralized exchange and want to bridge to a different chain without an additional transaction.
- Onboarding Flows from Fiat Rails — For applications that need to seamlessly move funds from fiat onramps to specific destination chains without requiring users to understand intermediate bridging steps.
- Wallet Connection Issues — In situations where wallet connection or transaction signing is problematic, such as when the wallet provider doesn’t support the origin chain or when building headless/automated bridging systems.