Skip to main content
ForexCopilotEA

United States

Can You Run an Expert Advisor on a US Forex Account? NFA FIFO, No-Hedging and Leverage Rules Explained

By Benjamin Lee · Updated · 10 min read

Yes, in principle. The rules I checked regulate the dealer's accounts and leverage, not the use of automation, and the CFTC says automated programs may help with trading discipline. But two rules change what an EA can do on a US account. Offsetting positions must be closed first-in, first-out, so classic hedging is not available, and minimum security deposits of 2% or 5% cap leverage at roughly 50 to 1 and 20 to 1. That hits grid, martingale and hedge-style EAs hardest. This guide explains what the rules say, what they mean for MT5, and how to check your own broker. It is general information, not legal advice, and rules can change.

Key takeaways

  • NFA Compliance Rule 2-43 requires forex dealers to offset positions first-in, first-out and bars them from carrying offsetting positions in a customer account.
  • US retail forex margin has a floor of 2% for major pairs and 5% for others, so leverage is lower than many offshore offers.
  • Grid and martingale EAs use more margin than their per-trade size suggests, so test them under US margin settings.
  • Hedge-style EAs that hold a buy and a sell together may not work as designed. Ask your dealer how it handles this.
  • Check registration in NFA BASIC, read the account agreement, and test the EA on a demo account from the same dealer.

The short answer

Nothing in the NFA and CFTC material I read prohibits Expert Advisors as such. The rules apply to the forex dealer: how it offsets your positions, how much margin it must collect, and what it must disclose. An EA is simply software that places orders through your account, so it lives inside those limits like any manual trade.

What changes is the set of strategies that behave as designed. An EA built and tested on an offshore hedging account with high leverage may not behave the same way when it meets first-in, first-out offsetting and a 2% or 5% margin floor. That is a strategy-fit problem, and you can find it before you risk money.

Who sets the rules for US retail forex

The CFTC says that registration and examination of intermediaries is conducted on behalf of the CFTC by the National Futures Association (NFA), under the CFTC's supervision. Retail forex dealers that act as your counterparty are registered with the CFTC and are NFA members. The CFTC also warns that when you trade on a platform you are connecting to the dealer, not to an exchange, and that you are trading against the dealer unless you use regulated exchange products.

That framing matters for EAs. Your EA does not talk to a market. It talks to a dealer's platform, and the dealer's rulebook obligations decide what that platform may do with your orders.

FIFO and offsetting: the rule behind "no hedging"

NFA Compliance Rule 2-43, titled Forex Orders, includes section (b) on offsetting transactions. In summary, forex dealer members may not carry offsetting positions in a customer account. They must offset them on a first-in, first-out basis. At the customer's request, a dealer may offset same-size transactions even when older transactions of a different size exist, but it must offset against the oldest transaction of that size.

Traders shorten this to "no hedging" and "FIFO". Read literally, the rule is addressed to the dealer, and it describes how offsetting positions are treated. It does not tell you which EA settings to use. How your dealer's MT5 server implements the rule is a question for the dealer, and I did not find a primary source that describes platform-level behavior.

A small FIFO illustration

Suppose, hypothetically, an EA buys 0.10 lot, then 0.20 lot, then 0.10 lot on one pair. A sell of 0.10 lot would offset the oldest transaction first, which is the first 0.10 lot buy. If you asked the dealer to offset the 0.20 lot position, the rule lets it offset same-size transactions at your request, against the oldest of that size. The point for an EA is that you cannot assume the position you meant to close is the one that closes. Test how your dealer handles partial closes and close-by orders.

Leverage: the 2% and 5% margin floor

CFTC Regulation 5.9 requires dealers to collect a minimum security deposit for each retail forex transaction. The deposit is set by the registered futures association and cannot be less than 2% of notional value for major currency pairs and 5% for all other pairs. The 2% rate applies only when both sides of the pair are major currencies. NFA Financial Requirements Section 12 sets the same percentages and names the currencies it treats as major: the British pound, Swiss franc, Canadian dollar, Japanese yen, euro, Australian dollar, New Zealand dollar, Swedish krona, Norwegian krone and Danish krone. NFA's text was last amended on March 18, 2026.

Dividing 100% by the margin rate gives the equivalent leverage: about 50 to 1 at 2% and 20 to 1 at 5%. The CFTC uses the same example, noting that a 2% requirement means you could open a $100,000 position with $2,000. Two more points from the rules. NFA can temporarily raise the requirements under extraordinary market conditions, and a dealer must collect more margin or liquidate positions when your deposit falls short. An EA cannot negotiate with a margin call.

Margin floor in US retail forex, as stated in the rules
ItemWhat the rule saysEquivalent leverage
Major currency pairsAt least 2% of notional valueAbout 50 to 1
All other pairsAt least 5% of notional valueAbout 20 to 1
Temporary increasesNFA may raise requirements in extraordinary conditionsCan be lower than the usual limit
Insufficient depositDealer must collect more margin or liquidate positionsNot applicable
Gold, indices, other CFDsNot verified here. Ask your dealer which rules applyCheck with your broker

The CFTC lists an offer of leverage higher than legally allowed in the United States as a fraud warning sign. If a broker advertises far higher leverage to US residents, treat that as a reason to check its registration before sending money.

Worked example: what US margin does to a grid or martingale EA

These numbers are hypothetical and simplified. Assume a $5,000 account, USD as the account currency, and a notional value of $10,000 for the first level of each strategy. The figures ignore floating losses, spread and swaps. In real conditions losses reduce equity, so the margin pressure is worse than shown.

Hypothetical margin use on a $5,000 account (USD)
EA patternTotal notional if fully openMargin at 2%Margin at 5%Share of account at 2%
Grid, 8 levels of $10,000 each$80,000$1,600$4,00032%
Martingale, 5 levels doubling ($10,000, then $20,000, $40,000, $80,000, $160,000)$310,000$6,200$15,500124%

The grid fits, with room to spare at the 2% rate, but at 5% it would use 80% of the account before any losses. The doubling martingale needs more margin at its fifth level than the whole account holds, so the fifth order would not be supported. Higher leverage would hide that limit for longer, but it would not remove the loss exposure underneath. If your EA was tested at 500 to 1, rerun the test with a margin level that matches your US account.

To size this for your own numbers, use the margin calculator and the lot size calculator.

What this means for common EA types

EA styles and the US account questions to ask
EA styleMain US account concernWhat to do
GridMany same-direction positions use margin quickly and are closed in FIFO orderBacktest with 2% or 5% margin and confirm close behavior on demo
MartingaleDoubling sizes hit the margin floor early and can trigger liquidationCap the number of steps and test the worst case
Hedging or lockingBuy and sell positions cannot be carried as separate offsetting positionsAsk the dealer in writing how it handles the second order
Single-trade, stop-basedLeast affected, since each trade stands aloneStill verify margin and order handling on demo
ScalperNo minimum holding rule found in the sources I checkedCheck the dealer's terms on execution and trade frequency

For strategy mechanics, see grid trading explained, martingale risks and the strategy comparison. MT5 can run as a netting or a hedging account type, which is a platform setting your broker chooses. The hedging versus netting guide shows how each changes EA behavior. A US dealer's account type is a separate question from NFA's rule, so ask the dealer how the two fit together.

A note on strategies that rely on recovery

The CFTC warns that automated trading programs and bots are tuned to past conditions, and that there is no way of knowing whether the same conditions will persist. It also reports that about two out of three retail forex traders at registered US dealers end each quarter with a loss. Lower leverage is not a safety net, but it does force position sizing to be explicit, which is not a bad thing for an EA that relies on adding to losing trades.

How to check your broker before you run an EA

  1. Step 1: Look up the firm in NFA BASIC

    BASIC is NFA's free database of CFTC registration, NFA membership and disciplinary history for futures and retail forex firms. The CFTC advises checking registration before researching a strategy or product.

  2. Step 2: Read the account agreement and risk disclosure

    The CFTC says dealers must give you account and risk disclosure documents before you open an account. If you do not receive them, it considers that a red flag.

  3. Step 3: Ask in writing how offsetting works on MT5

    Ask what happens when an EA sends an opposite order on the same instrument, how partial closes are matched, and which margin rates apply to each symbol you trade.

  4. Step 4: Run the EA on a demo account from the same dealer

    Demo conditions are not identical to live, but they expose rejected orders and close-order behavior. See forward testing on demo.

  5. Step 5: Start with a size you can afford to lose

    The CFTC advises using only risk capital, not money needed for living expenses or savings, and having a written risk plan before you trade.

Some offshore brokers market hedging and high leverage to US traders. The CFTC notes that registration alone does not prevent fraud, but most fraud involves unregistered entities, and it lists accepting only crypto payments and no verifiable US presence as warning signs. This article does not advise using an unregistered dealer, and your recourse is weaker if you do. For the Europe comparison, see ESMA rules for EA traders.

Before running an EA on a US account
0/7

Sources and further reading (checked October 30, 2026)

  1. NFA Compliance Rule 2-43, Forex OrdersSection (b) covers offsetting transactions and first-in, first-out treatment.
  2. NFA Financial Requirements Section 12Minimum security deposits of 2% and 5% and the list of major currencies.
  3. CFTC Regulation 5.9 (eCFR API text)Security deposit floor for retail forex and the both-sides-major condition.
  4. CFTC Customer Advisory: Eight Things You Should Know Before Trading ForexTrading against the dealer, margin example and registration benefits.
  5. CFTC Forex FraudsAutomated trading programs, loss statistics, leverage warning sign and do's and don'ts.
  6. CFTC: Check registrationWhy to verify registration and disciplinary history first.
  7. NFA BASICThe free lookup for registration, membership and disciplinary history.

Frequently asked questions

Can I use a trading robot on a US forex account?

The NFA and CFTC sources I checked regulate the dealer's offsetting, margin and disclosures, not the use of automation. The CFTC says automated programs may help with trading discipline but cannot reliably predict markets. Confirm in your account agreement that your dealer permits automated trading on its platform.

What does FIFO mean for an Expert Advisor?

NFA Rule 2-43(b) requires forex dealers to offset positions first-in, first-out, with a limited same-size exception at the customer's request. An EA that expects to close one specific ticket may find the dealer applies the oldest matching position instead, so test close behavior on a demo account.

Is hedging allowed on a US forex account?

The rule says dealers may not carry offsetting positions in a customer account and must offset them instead. How your dealer's MT5 server enforces that, by rejecting the order or offsetting it, is a dealer-level question. Ask in writing and test on demo.

What is the maximum leverage on a US forex account?

The CFTC floor is a 2% security deposit for major pairs and 5% for other pairs, which works out to about 50 to 1 and 20 to 1. NFA lists ten major currencies, may raise requirements temporarily, and your dealer's margin table governs each symbol.

Can I run a grid or martingale EA under these rules?

Not by rule alone, but they use margin quickly and may close in FIFO order. Backtest at your account's real margin rates, cap the number of steps, and confirm how your dealer handles multiple positions. These strategies can lose heavily in a prolonged move.

How do I check that a forex broker is registered?

Search the firm in the NFA BASIC database, which shows CFTC registration, NFA membership and disciplinary history. The CFTC says registration will not stop all fraud, but most fraud involves unregistered entities.

Expert Advisors in these styles

Apply the checks above to any of these before you buy: read the manual, run your own backtest, and start on demo.