Binance API Responses: Price Filter and Percent Price

Binance API Responses: Price Filter and Percent Price

Intermediate
Updated Dec 16, 2025
9m

Key Takeaways

  • Binance uses filters on each trading pair to make sure that all orders comply with the trading rules related to price, quantity and value.

  • An order parameter breaking one or more of the trade limitations results in a filter failure error being raised.

  • Price filters and percent price filters are the usual filters that restrict the extreme or invalid prices, thus protecting positions against market instability.

  • Getting the valid trading parameters for each symbol, using /exchangeInfo and /myFilters API before making an order, helps in avoiding rejections.

  • Client-side validation reduces the chances of unsuccessful or delayed trades and ensures smooth API execution.

Binance Academy courses banner

Introduction

Every order placed via the Binance API is handled based on a predetermined set of filters. For order characteristics like price, quantity and notional amount, the filters specify the acceptable values. Additionally, they guarantee that all transactions stay inside the exchange's bounds and do not risk the stability and equity of the market.

In case an order does not comply with any of these filters, the Binance API will not accept it and will send back a filter failure message. Usually, it is the case that one or more order attributes (i.e., price or volume) go beyond the limits set by the maximum or minimum. Therefore, developers and traders who are trading through API must be aware of how these filters operate so as to minimize rejections and to increase their trust in the trading system.

This article will describe filters, analyze two common ones (PRICE_FILTER and PERCENT_PRICE_BY_SIDE) and explain when and how to manage failures.

What Are Filters in Binance API?

Filters are sets of rules that Binance has defined to check every order before its execution. Individually configured for each account, asset, and trading pair, those filters specify the valid range and precision for order parameters like price, quantity, and notional value.

These limitations safeguard traders as well as the market by only allowing logical, executable, and considerate orders to be submitted in line with current conditions. Without filters, the trading activity could be affected or misdirected by wrong formatting or extreme orders being placed.

All the filters set for a specific symbol can be accessed using the Binance API /exchangeInfo and /myFilters endpoints. The endpoints would show such details as minimum and maximum prices, quantity steps and percentage limits that orders should comply with.

Among the filters that are most frequently used are the following:

  • PRICE_FILTER – Sets the lowest, highest and tick size (the minimum price increment allowed) for prices.

  • PERCENT_PRICE_BY_SIDE – Controls the price of an order to not deviate too much from the last trade or mark price. It also defines limits for both bid and ask.

  • LOT_SIZE – Defines the minimum, maximum and step size for order quantities. Applies to both limit and market orders.

  • NOTIONAL – Ensures an order’s total value falls within the allowed notional range. It can enforce minimum and optional maximum limits and may apply to limit orders, market orders or both.

  • MARKET_LOT_SIZE – Defines allowed quantity ranges specifically for market orders. Useful when market orders have different limits from limit orders.

In the event of an order breaching any of these restrictions, the API will respond with a filter failure error specifying which filter has been activated. Knowledge of these restrictions and proactive checking of the order parameters will assure quicker processing and will not result in unnecessary rejections.

Common Filter Failures

An order filter failure occurs when the conditions of one or more of the filter parameters fail for a specified trading pair. Filters are enforced before an order is accepted by the exchange to make sure the values involved are legitimate, valid and are within set limits for the market.

The Binance API, when a trade violates a rule, will throw an error like the following:

{

  "code": -1013,

  "msg": "Filter failure: PRICE_FILTER"

}

This message means that the order did not pass through the order validation layer for the exchange. In this case, the price value provided was not within the allowed range or the required tick size did not match the allowed values.

The most common causes of order filter failures are:

  • Using a price smaller than the minimum or above the maximum allowed.

  • Using an order price or quantity that does not conform to the allowed decimal amount precision.

  • Placing an order with a notional total that is smaller than the allowed minimum for the trade.

  • Using a price more than the allowed or stated difference from the current market price.

Order filter failures are not system errors as such; they are protective mechanisms. They ensure that all trades conform to the trading specifications for the symbol and that the order book is fair, e.g., the order price must follow the symbol’s allowed price increments (tick size) and stay within the permitted price range.

The following two sections describe two of the more common order filters in the exchange: Price Filter and Percent Price Filter, when failures occur and how they can be handled effectively.

Price Filter

The Price Filter (PRICE_FILTER) defines limits and granularity for the valid range of prices for a trading pair. It makes sure every order price conforms to the limits and tick sizes configured by the market.

Every Binance symbol has three filter parameters that describe the symbol:

  • minPrice – minimal price allowed.

  • maxPrice – maximal price allowed.

  • tickSize – the smallest price change allowed.

Reasons for Price Filters Error Returns

When PRICE_FILTER is thrown, the most frequent reasons are:

  • Tick size constraints are broken.

  • Order price is too low, too high or outside of the range.

  • Small rounding inconsistencies from floating-point arithmetic.

A failing example is trying to send a limit order to buy BTCUSDT where the market is set to 2 decimal places (tickSize: 0.01) and the order price is set to 110,384.123.

How to Resolve Price Filter Errors

Always refer to symbol-specific trading rules from the /exchangeInfo and /myFilters endpoints prior to submitting any order. Through these endpoints, users can access PRICE_FILTER data relating to each trading pair, assisting developers with local price validation.

Best approaches:

  • Adjusting prices using the specified tickSize (e.g., floor, round).

  • Applying limits to order prices (checking against minPrice and maxPrice).

  • Avoiding unnecessary API rejections by validating trading rules beforehand.

Percent Price Filter

The Percent Price Filter (PERCENT_PRICE_BY_SIDE) defines how far an order’s price is allowed to deviate from the reference price (last trade or mark price). Its purpose is to prevent orders from being submitted at prices that are unreasonably far from the market and could result in illogical or unintended executions.

This filter uses four key parameters:

  • bidMultiplierUp / bidMultiplierDown – Apply to BUY (bid) orders

  • askMultiplierUp / askMultiplierDown – Apply to SELL (ask) orders

These values define the allowed upper and lower bounds for order prices on each side of the book. The order price must remain within the following range:

For BUY (bid) orders:

  • lowerBound = averagePrice × bidMultiplierDown

  • upperBound = averagePrice × bidMultiplierUp

For SELL (ask) orders:

  • lowerBound = averagePrice × askMultiplierDown

  • upperBound = averagePrice × askMultiplierUp

Order price must fall within the appropriate range, depending on whether users are buying or selling.

Reasons for Percent Price Filters Error Returns

A Percent Price filter failure occurs when an order’s price is too far from the current market range.

Common cases include:

  • Submitting a BUY order above the allowed upper bound.

  • Submitting a SELL order below the allowed lower bound.

  • Using stale or outdated market prices when calculating order values.

  • Attempting to place orders during periods of rapid volatility.

For example, if BTCUSDT trades around 110,000 USDT and the BUY-side multipliers are 0.2 and 5.0, the filter may allow BUY orders anywhere between roughly 22,000 and 550,000 USDT. Orders outside this range will be rejected and return a PERCENT_PRICE_BY_SIDE failure.

How to Resolve Percent Price Filters Errors

To prevent Percent Price filter violations:

  • Retrieve the latest percent price filter values using /exchangeInfo or /myFilters.

  • Ensure you check the correct side-specific multipliers before placing BUY or SELL orders.

  • Refresh reference prices frequently, especially during volatile market conditions.

  • Implement retry logic that adjusts the price to the nearest valid bound if needed.

Handling Filter Failures Programmatically

When a filter violation occurs, the Binance API returns a structured error message identifying the failed filter type. These responses help developers quickly diagnose and correct invalid parameters before retrying.

A typical error response looks like this:

{

  "code": -1013,

  "msg": "Filter failure: PRICE_FILTER"

}

To handle these errors effectively in automated trading systems:

  1. Inspect the error code and message:

    1. The error code -1013 indicates a filter failure.

    2. The message specifies the exact filter, such as PRICE_FILTER, PERCENT_PRICE_BY_SIDE, NOTIONAL, etc.

  2. Validate before submission:

    1. Retrieve trading rules via the /exchangeInfo and /myFilters endpoints once at startup and cache them locally.

    2. Use these filter parameters to pre-validate orders on the client side before making API calls.

  3. Implement adaptive logic:

    1. If a filter error occurs, adjust order parameters dynamically (e.g., rounding prices or resizing quantities) within valid limits.

    2. Avoid blind retries without correction.

  4. Monitor for symbol updates:

    1. Filter configurations can change over time as markets evolve.

    2. Periodically refresh data by querying Binance API to keep validation rules accurate.

Proactive validation is the most reliable way to prevent filter failures. By handling filters programmatically, developers ensure that trading bots, portfolio systems and order routers interact with Binance efficiently and without interruptions.

Example: Price Filter Failure on a Limit Order

The following example shows a limit order that fails the PRICE_FILTER because the submitted price does not align with the symbol’s tickSize. It then demonstrates a corrected submission.

Example: Price Filter Failure on a BTCUSDT Limit order

Code Snippet
from binance_sdk_spot.spot import Spot, SPOT_WS_API_PROD_URL, ConfigurationRestAPI
from binance_sdk_spot.rest_api.models import NewOrderSideEnum, NewOrderTypeEnum, NewOrderTimeInForceEnum

configuration_rest_api = ConfigurationRestAPI(
    api_key=os.getenv("API_KEY", ""),
    private_key='your-ed25519-private-key-content-or-file-path',
)

client = Spot(config_rest_api=configuration_rest_api)

def new_order():
    bad_price = 110000.4567
    try:
        client.rest_api.new_order(
            symbol="BTCUSDT",
            side=NewOrderSideEnum.BUY,
            type=NewOrderTypeEnum.LIMIT,
            time_in_force=NewOrderTimeInForceEnum.GTC,
            quantity=1,
            price=bad_price
        )
    except Exception as e:
        if "PRICE_FILTER" in str(e):
            try:
                exchange_info = client.rest_api.exchange_info(symbol="BTCUSDT").data()
                price_filter = next(f.actual_instance for f in exchange_info.symbols[0].filters if f.actual_instance.filter_type == "PRICE_FILTER")
                tick_size = float(price_filter.tick_size)
                min_price = float(price_filter.min_price)
                max_price = float(price_filter.max_price)

                fixed_price = (bad_price // tick_size) * tick_size
                fixed_price = min(max(fixed_price, min_price), max_price)
                print(f"Correcting price from {bad_price} to {fixed_price}")

                res_good = client.rest_api.new_order(
                    symbol="BTCUSDT",
                    side=NewOrderSideEnum.BUY,
                    type=NewOrderTypeEnum.LIMIT,
                    time_in_force=NewOrderTimeInForceEnum.GTC,
                    quantity=1,
                    price=fixed_price
                )
                print(f"Corrected order accepted: {res_good.data()}")
            except Exception as e:
                print(f"Error while correcting and placing order: {e}")
        else:
            print(f"An unexpected error occurred: {e}")

if __name__ == "__main__":
    new_order()

Closing Thoughts

Filters are essential to keep fair and orderly markets on Binance. They are designed to make sure each order that is submitted via the API conforms with certain rules on price, quantity, and notional value so as to prevent invalid or disruptive trades.

For developers and traders who use the Binance API, it’s important to know how these filters operate. Most filter failures can be prevented by checking order parameters with the /exchangeInfo and /myFilters data prior to submission.

By adding these validations to trading strategies, developers can reduce failed orders and reduce latency caused by retries, as well as give their strategies a better chance at running safely within the Binance rules of the road.

Smart automation starts with compliance, and filters are a beginning part of creating resilient, quality API integrations.

Further Reading

Disclaimer: This article is for educational purposes only. This content is presented to you on an “as is” basis for general information and educational purposes only, without representation or warranty of any kind. It should not be construed as financial, legal or other professional advice, nor is it intended to recommend the purchase of any specific product or service. You should seek your own advice from appropriate professional advisors. Products mentioned in this article may not be available in your region. Where the article is contributed by a third party contributor, please note that those views expressed belong to the third party contributor, and do not necessarily reflect those of Binance Academy. Please read our full disclaimer here for further details. Digital asset prices can be volatile. The value of your investment may go down or up and you may not get back the amount invested. You are solely responsible for your investment decisions and Binance Academy is not liable for any losses you may incur. This material should not be construed as financial, legal or other professional advice. For more information, see our Terms of Use and Risk Warning.