Stargatebridge fees and transfer quote components
Stargatebridge fees for v2 transfers include token-denominated protocol charges, cross-chain messaging costs and source-network gas. Pool rewards can offset the token charge under qualifying conditions. Bus shares messaging costs through batching, while Taxi sends individual messages. Optional destination gas and contract calls change the quoted payment.
The token difference gives the protocol charge
In a Stargate v2 quote, the protocol charge equals the quoted amount sent minus the quoted amount received, using matching token units. A positive difference represents a charge. A negative difference represents a net token reward where the pool rules permit one. The quoted output already incorporates that adjustment, so subtracting the protocol charge again would count it twice.
The
quoteOFT
function returns token amounts, fee details and transfer limits. If the requested input exceeds the reported maximum, it quotes the capped amount instead. Separately,
quoteSend
returns the messaging payment. A zero token charge can therefore accompany a payable messaging fee. Source transaction gas adds another expense outside the token adjustment.
Token units and native currency need separate accounting
Transfer-token amounts
The v2 token quote expresses its receipt amounts in the source asset's local decimal units. These integers need the asset's decimal scaling before they become readable token quantities. Shared decimals provide the common precision that the protocol uses across chains. Comparing raw balances from different decimal systems can create an apparent fee that is simply a unit mismatch.
Wallet funding
An ERC-20 pool transfer supplies the transfer token separately from the native messaging payment. A native-coin pool transfer includes the principal alongside that payment in the transaction value. The principal remains the asset that the user transfers. Comparing expenses across different currencies requires a common valuation basis; adding their raw quantities does not produce a meaningful total.
FeeLibV1 applies amount bands and pool conditions
FeeLibV1 uses destination-specific token fee and reward settings on Stargate v2 routes configured with this library.
The fee-bearing amount
The fee-bearing amount selects one of three configured bands, whose rate applies to that whole amount. For positive fee-bearing amount B and positive rate r, FeeLibV1 calculates the fee in shared units as floor(B × r / 1,000,000) + 1. A zero configured rate produces no library fee. In this formula, B counts integer shared units and r is the selected band's configured rate in parts per million.
Deficit-related rewards
For a source Pool instance with a positive deficit and nonzero reward rate, the reward calculation covers the amount up to that deficit. Any excess enters the fee calculation. A Hydra OFT origin uses the fee branch instead. Pools cap a positive net reward at the available treasury balance, so the raw reward calculation alone does not establish the final output.
Bus riders pay a configured share of messaging costs
A v2 Bus rider pays a destination-specific fare that distinguishes ordinary transfers from transfers requesting native currency on arrival. The Bus fare estimator divides the batch's quoted native messaging fee by the passenger count supplied to that calculation. The Planner sets the fares that riders actually pay. This distinction prevents treating the current queue occupancy as a promise that every additional rider will reduce an existing rider's payment.
Taxi obtains a quote for an individual message and avoids the Bus batching wait. Its messaging price reflects the message and execution options. A meaningful price comparison keeps the route, asset and amount consistent, alongside any destination options. Comparing a plain Bus payout with a Taxi transfer that includes a contract call compares different services.
Destination gas funding changes what the quote pays for
Adding destination gas funds a native-currency top-up alongside the bridged asset. When the top-up succeeds, the recipient can use that currency for later destination transactions. The extra payment includes value intended for delivery, alongside the messaging costs. Source payment and destination delivery also have their own currency units.
The v2 transfer interface permits only the default destination-gas amount for Bus transfers. Taxi allows a custom amount. The available top-up therefore depends on the selected mode, and the default Bus amount does not establish a universal allowance across every destination.
The messaging quote already prices its selected execution options. Adding a second estimate for that same destination execution can count the service twice. Later wallet activity has its own transaction costs, even when the optional top-up supplies the currency that pays them.
Approval gas changes the source wallet expense
An ERC-20 transfer may require approval when the existing token allowance is insufficient. If that approval uses a separate transaction, it adds source-network gas before the transfer transaction. An existing sufficient allowance changes that expense. The bridge quote alone therefore cannot establish the gas cost of every transaction that a particular wallet needs.
Source execution gas remains separate from the messaging payment, even when both use the same native currency. On EVM source networks, execution that reverts can still consume gas. A failed transfer therefore does not establish that the wallet spent nothing.
Destination contract calls require their own execution budget
A composed Taxi transfer needs execution funding for its destination callback in addition to token delivery. The receiving contract's logic determines the callback's gas requirements. The quote must include the execution options for that actual operation. A gas allowance copied from an unrelated callback does not establish sufficient funding.
Bus does not support composed destination calls. A downstream swap also has its own pricing conditions, separate from the bridge's token adjustment. Those application costs belong in a comparison of the full requested operation, while a plain transfer quote covers a narrower task.
Transfer size and changing state affect the quote
A different transfer amount can cross a configured fee band or exceed the portion eligible for a pool reward. The effective percentage can therefore change with the amount. Available route credit also constrains the transfer. Paying a larger messaging fee does not increase that credit.
The minimum-output parameter constrains the token result that execution will accept. The v2 send rounds the minimum down to shared precision and reverts if the adjusted output falls below it or equals zero. Messaging prices can also change as gas prices or service charges move. A quote describes the selected inputs and pricing state; an older payment amount may no longer cover the required fare.
Matching Bus quotes show the destination-gas price difference
Two Bus quotes, with destination gas enabled and disabled, price different deliveries. Keeping the route, token amount and pricing state fixed isolates the quoted cost of that option. The difference between their native payments includes the funding and associated messaging costs that the selected fare covers. It does not equal the quantity of destination currency that the recipient receives.
- Keep the same source asset, destination pathway and transfer amount in both quotes.
- Compare the plain Bus fare with the fare that includes the native drop.
- Read the offered destination-gas amount separately from the source-native payment.
- Keep the token adjustment and wallet transaction gas outside that fare difference.
- Use a custom-amount Taxi quote if the required top-up differs from the Bus option.
The comparison changes if the configured Bus top-up or pathway fare changes. It also changes when the requested service includes a composed contract call.
Stargatebridge fees: quick answers
-
Can Stargate v2 Bus fares use the LayerZero token payment option?
- Stargate v2 Bus transfers do not accept a nonzero LayerZero-token messaging fee. The Bus sending path rejects that payment field. Taxi has a separate payment branch, which requires the relevant token configuration when the caller supplies a LayerZero-token fee. This distinction concerns messaging payment, not the asset being bridged.
-
Where does excess native currency go when a Bus fare is overpaid?
- The v2 Bus sending path attempts to return excess fare to the refund address supplied with the transfer. That address can differ from the sending wallet and must accept native currency for the refund to succeed. The refund covers the difference between the supplied messaging payment and actual fare, excluding source transaction gas.
-
Why can OFTFeeDetail show a negative protocol fee?
- Stargate v2 uses a negative fee detail for a protocol deduction and a positive detail for a reward. The sign describes the adjustment to token output. It differs from expressing a charge as a positive expense, so a negative protocol-fee entry does not mean that the sender earned a rebate.
-
What happens to a Bus gas top-up that the recipient cannot receive?
- A failed Bus native drop does not automatically refund the recipient or source sender. In a batch that completes, the v2 Bus receiver records the drop failure, proceeds to the bridged-token receiving call and sends remaining destination native currency to the Planner. This treats the gas top-up separately from delivery of the bridged asset.
-
Does requesting a v2 fee quote reserve route credit?
- A v2 quote does not reserve route credit. The quoting functions read the current state without executing a transfer. The send later consumes the required path credit, so a quoted amount and fee do not themselves secure capacity for a future transaction.
-
Can redeeming liquidity-provider tokens add a cross-chain messaging fee?
- A cross-chain redemption through v2 redeemSend includes Taxi messaging costs and the applicable token adjustment. A local redeem operation returns the underlying asset on the same chain without sending that cross-chain message. The operation selected therefore determines whether cross-chain messaging belongs in the redemption's cost.
-
Why can a tiny transfer fail before a messaging quote appears?
- The v2 messaging quote rejects an amount that becomes zero after conversion to shared precision. The source asset's decimal settings determine that conversion. Increasing a messaging payment cannot make a zero shared-unit transfer valid, and a displayed fractional token amount alone does not establish that it meets the protocol's precision requirement.