Fee Glossary

Relay quotes include the following fees: gas, relayerService, and relayerGas. The two relayer fees (service and gas) are combined to make the full relayer fee.

gas: The gas fee to be paid on the origin chain to execute the transaction. This is usually paid by the user to deposit funds to the relayer to initiate the bridge or swap.

relayer: The sum of the relayerService and the relayerGas.

relayerService: The service fee paid to the relayer to facilitate execution.

relayerGas: The gas fee given to the solver to pay gas fees on the destination chain.

appFees: Third party fees added on top of the existing fees, this fee is added by app developers and accrues offchain to minimize gas costs.

Gas fees are estimates and may fluctuate over time, if using in a calculation we recommend adding a small buffer to account for these fluctuations.

What are app fees?

App fees are additional fees set by third-party developers on top of existing fees. These fees are specified when generating a quote and accrue off-chain, meaning they are not immediately paid out. Instead, the app fee payee must manually claim them later.

App fees are measured in basis points (bps) based on the input value of an order. When setting an app fee, a claim address must be provided, which will be used for withdrawing accumulated fees. A single quote can include multiple app fees.

You can accrue fees by including appFees in the Quote API.

Since app fees accrue off-chain, we maintain a database that tracks:

  • The app fee payee address
  • The currency in which fees are accrued
  • The total claimable balance per currency

How do app fees work?

App fees behave differently depending on whether the request is cross-chain or same-chain.

Cross-Chain

  • The app fee accrues in the currency sent to the solver.
  • The app fee is recorded after the fill transaction is completed.

Same-Chain

  • App fees apply only to swaps—not to wraps, unwraps, or sends.
  • App fees apply only to EVM same-chain swaps. Solana is not currently supported.
  • Fees are added in the form of the native currency. Even if the user isn’t initially spending native currency, they may still need to pay a small amount of it. For example, swapping $MOG -> $MEME may still require paying some ETH as an app fee.
  • Important: The app fee must be paid, or the transaction will fail.
  • If the input currency is native currency, instead of adding extra funds, the fee is deducted from the original amount being sent.
  • The fee is recorded only after the same-chain transaction is indexed.

Claiming App Fees Across Chains

App fee payees must claim accrued fees for major currencies (ETH, USDC and USDT) on Base regardless of the origin chain. Other currencies must be claimed on origin chain of the request.

How to know your offchain balance?

To check your accrued off-chain fees, use the app fee balances API. Here’s an example curl command:

curl --location 'https://api.relay.link/app-fees/0x03508bb71268bba25ecacc8f620e01866650532c/balances' 

The response includes the balances.currency field, reflecting your off-chain balance for each currency accumulated:

    {
      "currency": {
        "chainId": 8453,
        "address": "0x0000000000000000000000000000000000000000",
        "symbol": "ETH",
        "name": "Ether",
        "decimals": 18,
        "metadata": {
          "logoURI": "https://assets.relay.link/icons/1/light.png",
          "verified": false,
          "isNative": false
        }
      },
      "amount": "75021651210714015",
      "amountFormatted": "0.075021651210714015",
      "amountUsd": "116.235557",
      "minimumAmount": "75021651210714015"
    }

How to claim your off-chain balance?

To claim your app fees, use the app fees claim API. If using the API, the response will guide you through signing and submitting a message to the /execute/permit endpoint to verify ownership of your claim address. The SDK automates this process for you.

curl --request POST \
  --url https://api.relay.link/app-fees/0x03508bb71268bba25ecacc8f620e01866650532c/claim \
  --header 'Content-Type: application/json' \
  --data '{
    "chainId": 8453,
    "currency": "0x0000000000000000000000000000000000000000",
    "recipient": "0x03508bb71268bba25ecacc8f620e01866650532c"
}'

An example response from the API would be:

{
    "steps": [
        {
            "id": "authorize",
            "action": "Sign authorization",
            "description": "Authorize claiming funds",
            "kind": "signature",
            "items": [
                {
                    "status": "incomplete",
                    "data": {
                        "sign": {
                            "signatureKind": "eip191",
                            "message": "0xa344c6123e3da9fc3f9c81edeab0b2eb39f2ea80ba54a6e0ad00123dc180619c"
                        },
                        "post": {
                            "endpoint": "/execute/permits",
                            "method": "POST",
                            "body": {
                                "kind": "claim",
                                "requestId": "0xa344c6123e3da9fc3f9c81edeab0b2eb39f2ea80ba54a6e0ad00123dc180619c"
                            }
                        }
                    }
                }
            ]
        }
    ]
}

You can then send a request to /execute/permit with the requestId and signature to claim your fees. An example request would be:

curl --request POST \
  --url `https://api.relay.link/execute/permits?signature=${signature}` \
  --header "Content-Type: application/json" \
  --data '{
    "kind": "request",
    "requestId": "0xa344c6123e3da9fc3f9c81edeab0b2eb39f2ea80ba54a6e0ad00123dc180619c"
  }'

Once done, you can check your balance again to verify the claim.