What Is the Futures Portfolio Bot?
The Futures Portfolio Bot is an automated tool that helps simplify the management of multiple futures contracts. You can combine multiple contracts into a portfolio and set the trading direction and target allocation for each contract. After the bot is created, the system establishes initial positions, continuously monitors the portfolio, and automatically executes according to your configured rules. With this tool, you can execute multi-contract strategies more efficiently and flexibly adjust your portfolio based on different market conditions.
How Does the Futures Portfolio Bot Work?
2.1 Bot Mechanism
When using the Futures Portfolio Bot, you can combine 2–10 contracts into a portfolio. You can configure each contract's trading direction, target weight, and portfolio leverage manually or by copying popular strategies. Once the bot is running, it continuously monitors the actual weight of each contract and automatically rebalances based on the allocation deviation threshold or fixed time interval you set, aiming to restore the portfolio to its preset allocations.
Building a Portfolio
A portfolio can include 2–10 USDT-margined perpetual futures contracts, with each contract set to either long or short. The target weight of each contract must be an integer, and the total must equal 100%.
Establishing Initial Positions
The system calculates the order quantity for each contract based on the investment amount, unified leverage, and target weights. To maintain a risk buffer, the bot does not use all funds as initial margin. The system determines the executable quantity based on order precision, minimum order requirements, fees, and market risk parameters.
Automatic Rebalancing
The Futures Portfolio Bot supports two automatic rebalancing modes:
-
Allocation-based rebalancing: When the deviation between the actual position weight and target weight of any contract in the portfolio exceeds the configured value, the system automatically rebalances the portfolio to restore each contract to its target weight. The actual rebalancing amount must meet the minimum order amount for the relevant contract.
-
Scheduled rebalancing: The system checks position weights at the configured time intervals. If the rebalancing amount resulting from changes in position weights meets the minimum order amount for the relevant contract, the system automatically rebalances the portfolio.
You can also manually trigger rebalancing while the bot is running. Due to price movements, order precision, minimum order quantities, risk limits, and available margin, rebalancing aims to bring the portfolio close to its target weights but does not guarantee an exact match with the configured values.
2.2 Bot Advantages
Flexibly build multi-contract portfolios: A single bot can manage 2–10 contracts and supports custom trading directions and target weights, reducing the operational effort required to place orders, verify positions, and maintain them individually.
Automatic rebalancing to maintain the target structure: You can choose allocation-based or scheduled rebalancing. When position weights reach the preset deviation threshold or the specified time interval is reached, the system automatically adjusts the portfolio to restore each contract as closely as possible to its target allocation.
Long and short portfolios for a range of strategy approaches: Supports all-long, all-short, or mixed long-short configurations. You can also set unified leverage and rebalancing conditions, making it easier to execute portfolio strategies such as trend, thematic, long-short hedging, and relative value strategies.
Multiple creation methods for greater flexibility: New users can refer to and copy popular public strategies. Experienced users can manually configure their own contracts, trading directions, target weights, leverage, and rebalancing rules.
2.3 Examples
The following examples use simplified data to illustrate the two rebalancing methods. For ease of understanding, fees, funding fees, slippage, quantity increments, and risk limits are not considered. Actual positions and order amounts are subject to the system's calculations and final execution results.
Example 1: Allocation-Based Rebalancing
Assume a user creates a mixed long-short portfolio with the following parameters:
-
Portfolio configuration: BTCUSDT, ETHUSDT, SOLUSDT
-
Unified leverage: 2x
-
Rebalancing mode: Allocation-based rebalancing, with a threshold of 5%
-
Investment amount: 4,000 USDT
-
Initial position calculation ratio: 50%, calculated and adjusted by the system based on risk conditions.
After market prices change, the position values and rebalancing directions of the contracts are as follows:
| Item | BTCUSDT | ETHUSDT | SOLUSDT |
|---|---|---|---|
| Trading direction | Long | Long | Short |
| Target weight | 45% | 35% | 20% |
| Initial position value (USDT) | 1,800 | 1,400 | 800 |
| Position value before rebalancing (USDT) | 2,200 | 1,200 | 600 |
| Actual weight before rebalancing | 55% | 30% | 15% |
| Rebalancing action | Sell to close long | Buy to open long | Sell to open short |
| Reference order amount (USDT) | 400 | 200 | 200 |
| Target value after rebalancing (USDT) | 1,800 | 1,400 | 800 |
BTCUSDT has a target weight of 45%. When the threshold is set to 5%, its permitted range is 40%–50%. Its current weight has reached 55%, exceeding the upper limit and triggering rebalancing. The system reduces the overweight BTCUSDT long position and increases the underweight ETHUSDT long and SOLUSDT short positions, bringing the portfolio back closer to its target structure of 45%, 35%, and 20%.
Example 2: Scheduled Rebalancing
Assume a user creates another portfolio with the following parameters:
-
Portfolio configuration: BTCUSDT, ETHUSDT, SOLUSDT
-
Unified leverage: 2x
-
Rebalancing mode: Scheduled rebalancing, checked every 4 hours;
-
Investment amount: 5,000 USDT;
-
Initial position calculation ratio: 50%, calculated and adjusted by the system based on risk conditions.
Under the simplified calculation, the portfolio's target total notional value at time T is 5,000 USDT. After 4 hours, the position values of each leg change as follows:
| Item | BTCUSDT | ETHUSDT | SOLUSDT |
|---|---|---|---|
| Trading direction | Long | Long | Short |
| Target weight | 50% | 30% | 20% |
| Position value at time T (USDT) | 2,500 | 1,500 | 1,000 |
| Position value at T+4H (USDT) | 2,650 | 1,350 | 1,000 |
| Actual weight at T+4H | 53% | 27% | 20% |
| Rebalancing action | Sell to close long | Buy to open long | No adjustment needed |
| Reference order amount (USDT) | 150 | 150 | — |
| Target value after rebalancing (USDT) | 2,500 | 1,500 | 1,000 |
At the 4-hour check, the system finds that BTCUSDT and ETHUSDT have each deviated from their target weights by 3%. If the order amounts meet minimum order requirements and pass risk checks, the system reduces the BTCUSDT long position and increases the ETHUSDT long position, bringing the portfolio back closer to its target structure of 50%, 30%, and 20%. SOLUSDT is already close to its target allocation, so no order is needed.
Risk Warning
-
Leverage and liquidation risk: Using leverage in futures trading amplifies both profits and losses. If margin is insufficient, some or all positions may be liquidated, and the bot may also terminate.
-
Multiple legs do not necessarily mean lower risk: Contracts may move unfavorably at the same time. A long-short portfolio may also experience rapid drawdowns if both legs incur losses simultaneously.
-
Rebalancing may amplify position changes: Automatic rebalancing increases or reduces positions according to target weights. If directional judgments remain incorrect, rebalancing cannot eliminate losses.
-
Slippage and execution risk: During sharp market movements or insufficient liquidity, the actual execution price may deviate from the price at the time of triggering. Rebalancing may also fail due to order specifications or risk restrictions.
Disclaimer
The content provided herein is for reference and educational purposes only and does not constitute any financial, investment, trading, or legal advice, nor does it constitute an offer or solicitation to buy or sell any digital assets. Gate makes no express or implied representations or warranties regarding the accuracy, completeness, or timeliness of the information contained herein. Product features, interfaces, rules, and fee structures may be updated or adjusted at any time. Please refer to the latest announcements and the actual information displayed on the Gate platform for the most accurate details.
Digital asset investments involve significant risk, and prices may fluctuate substantially. You may lose the entire amount of your investment. Please make decisions cautiously based on your own financial situation and risk tolerance after fully understanding the associated risks. If necessary, you are advised to consult an independent professional financial or legal advisor.
For more information about potential risks, please refer to Gate's Risk Disclosure and User Agreement.
