materraldocs

Using Materral

Costs. Every line between gross and net.

Net is gross minus five kinds of cost. Each one is shown as its own line with the evidence behind it: documented, measured, claimed by a venue, or an assumption.

The worked example#

Example. The numbers on this page are round and illustrative, not live data. The route: buy ETH on a Uniswap v3 0.05% pool on Arbitrum (quoted in USDC), sell ETH on Kraken (quoted in USD). Size $10,000. Gross spread $60.00 (60 bps).

Venue fee#

The taker fee charged by an order-book venue, on the filled notional. By default Materral uses the venue's published base tier. On HyperCore spot it is 0.07%.

Example. Kraken base tier 0.80% × $10,000 = $80.00.

If a fee could not be fully confirmed (Coinbase, Binance.US, Bitstamp), every route that uses it carries a warning. Enter your own tier to replace it; see Fees.

Pool fee#

A pool charges its fee tier inside the swap. It is already inside the pool's quote, so Materral adds it back when measuring gross and shows it once as its own line, marked "inside the quote". Uniswap pools here are 0.05% or 0.30%; Project X is 0.05%; nest's fee is dynamic and read from the pool before each quote.

Example. 0.05% × $10,000 = $5.00.

Gas#

Each on-chain leg costs network gas, valued at the chain's live gas price and the live price of its gas token.

  • Uniswap legs assume 150,000 gas units per swap, a typical figure rather than a measured one. Project X assumes 160,000 and nest 180,000.
  • On Arbitrum the L1 data cost is folded into the gas estimate.
  • On Base the separate L1 data fee is not included, and routes say so.
  • If a chain's gas price has not loaded yet, gas is left out and the route is flagged.
Example. 150,000 gas × 0.02 gwei × ETH at $3,000 ≈ $0.01.

Quote conversion#

Venues quote in different currencies: USD on Kraken, Coinbase and Bitstamp; USDT on Binance.US and OKX; USDC on the pools and HyperCore. Materral converts USDT and USDC prices to USD at the live Kraken USDT/USD and USDC/USD mids. A route that mixes quote currencies carries a quote-conversion cost:

  • half the live FX book's spread, for each stablecoin involved;
  • plus a stablecoin conversion fee of 0%, as OKX lists for USDT/USD and USDC/USDT.

If the FX book is missing, the route is not priced. Routes inside HyperCore that use USDT0 convert through the real @166 USDT0/USDC book, never at 1:1.

Example. Kraken USDC/USD spread of 1 bp, so a half-spread of 0.5 bps × $10,000 = $0.50.

Latency risk#

Legs are separate orders. While they are in flight, the price can move against you. Materral charges a one-sided 95% bound for that move:

latency risk = 1.65 × σ × √t × notional
  • σ is volatility per √second, from observed HYPE mids. Until enough have been observed, an 80% annualized volatility is assumed.
  • t is the slower leg's latency. Where a chain documents one it is used: 12 s on Ethereum, 1 s on Arbitrum, 2 s on Base. Elsewhere it is a 2 s assumption, which is shown.
Example. σ at 80% a year is about 0.000142 per √s. With t = 2 s (Kraken is unmeasured): 1.65 × 0.000142 × √2 × $10,000 ≈ $3.32.

Adding it up#

Example. Same illustrative route as above.
LineBase-tier feesOwn Kraken tier 0.10%
Gross spread+$60.00+$60.00
Venue fee, Kraken−$80.00−$10.00
Pool fee, Uniswap Arbitrum−$5.00−$5.00
Gas, Arbitrum−$0.01−$0.01
Quote conversion, USDC ↔ USD−$0.50−$0.50
Latency risk (2.0 s)−$3.32−$3.32
Net−$28.83 (needs +28.8 bps)+$41.17 (profitable)

The same gap flips from a loss to a profit on the fee tier alone. That is why Fees matters more than any other setting.

What is not a cost line#

  • Withdrawals. Cross-venue routes assume funds already sit on both venues.
  • Base L1 data fee. Not included, and flagged.
  • Wrapped-token conversion. WBTC, cbBTC, WETH, UBTC, UETH and USOL are valued 1:1 with a warning.

materral docs. Read-only, no keys, no real orders. Not investment advice.