RapidNode Docs
Back to WebsiteX/Twitter
  • Welcome
    • What is RapidNode?
  • Solana RPC Nodes
    • RapidNode RPCs Overview
    • Dedicated Nodes
      • Getting Started with Dedicated Nodes
    • Dedicated Staked Connections
    • Common Error Codes
  • RPC
    • HTTP
      • getAccountInfo
      • getBalance
      • getBlock
      • getBlockCommitment
      • getBlockHeight
      • getBlockProduction
      • getBlockTime
      • getBlocks
    • Websocket
  • Data Streaming
    • gRPC
    • Webhooks
  • Solana APIs
    • Priority Fee API
    • Enhanced Transaction API
    • Token Metadata API
  • Guides
    • RPC Proxy — Protect Your Keys
    • Sending Transactions on Solana
  • Resources
    • RapidNode Blog
    • SDKs
    • Transaction Types
    • Status Page
Powered by GitBook
On this page
  • What Are Priority Fees on Solana?
  • RapidNode Priority Fee API
  1. Solana APIs

Priority Fee API

Additional fees paid to prioritize transactions in the network

What Are Priority Fees on Solana?

Priority fees are optional fees you can add to your transactions to incentivize block producers (leaders) to include your transaction in the next block. You should include a priority fee in your transactions, but how much should you pay?

RapidNode Priority Fee API

RapidNode' getPriorityFeeEstimate is a RPC method that provides fee recommendations based on historical data. Most importantly, it considers both global and local fee markets.

To use this API, you must provide one of the following in the params:

  • transaction: A serialized, signed transaction. (recommended)

  • accountKeys: A list of account keys involved in the transaction.

Optional Parameters

  • transactionEncoding: Specifies the encoding of the transaction. Defaults to Base58, but can be set to formats like Base64.

  • priorityLevel: Allows you to set a custom priority level for the fee. The levels and their corresponding percentiles are:

    • Min: 0th percentile

    • Low: 25th percentile

    • Medium: 50th percentile

    • High: 75th percentile

    • VeryHigh: 95th percentile

    • UnsafeMax: 100th percentile (use with caution).

  • includeAllPriorityFeeLevels: If enabled, the API will return fee estimates for all priority levels.

  • lookbackSlots: Determines how many recent slots are analyzed to calculate the fee. Default is 50, with a range of 1–300.

  • includeVote: If true, it includes vote transactions for the fee calculation.

  • recommended: Provides a default recommended fee based on the median (50th percentile), excluding vote transactions.

  • evaluateEmptySlotAsZero: When enabled, the API treats empty blocks as zero-fee slots, lowering fee estimates during low congestion and preventing overpayment during minimal network activity.

PreviousWebhooksNextEnhanced Transaction API

Last updated 4 months ago