Margin & Leverage Risk Calculator

Stress a reader-entered long margin position against an entered maintenance requirement. See borrowed debit, gross leverage, financing drag, maintenance cushion, and how portfolio declines amplify into account-equity losses.

Margin assumptions

Use the current market value of the long position or long-only basket you want to stress.
The model infers borrowed debit as market value minus equity. Equity cannot exceed the modeled holdings value.
Enter the requirement that applies to your account or the stress level you want to test. The calculator does not choose a regulatory or broker house rate for you.
Used for a simple financing-cost estimate only. Broker rates can be tiered, variable, and accrued differently.
Enter 0 to ignore financing cost. The model allows up to 3,650 days.

Leverage and maintenance cushion

2xGross long leverage
$100,000Borrowed debit balance
$60,000Entered maintenance requirement now
$40,000Maintenance excess before financing cost
28.57%Modeled drawdown to entered requirement now
27.98%Modeled drawdown after entered financing period
$144,031Holdings value at entered requirement after financing period
$821.92Simple financing cost over entered days
50%Current holdings financed by borrowing

Current equity is 50% of the modeled holdings value. Before financing cost, maintenance excess equals 40% of current account equity.

Common-shock stress table

Each row applies the same percentage move to the full entered long holdings value, keeps the borrowed debit outstanding, adds the entered simple financing cost, and recalculates equity and maintenance excess. Real portfolios rarely move as one asset, so this is a leverage stress test rather than a security-by-security margin model.

Holdings moveHoldings valueEquity after interestEquity returnMaintenance excessCash to restoreStatus
+10%$220,000$119,178+19.18%+$53,178$0Above entered requirement
0%$200,000$99,178-0.82%+$39,178$0Above entered requirement
-10%$180,000$79,178-20.82%+$25,178$0Above entered requirement
-20%$160,000$59,178-40.82%+$11,178$0Above entered requirement
-27.98%$144,031$43,209-56.79%+$0$0Above entered requirement
-30%$140,000$39,178-60.82%-$2,822$2,822At / below entered requirement
-40%$120,000$19,178-80.82%-$16,822$16,822At / below entered requirement
-50%$100,000-$822-100.82%-$30,822$30,822At / below entered requirement
-75%$50,000-$50,822-150.82%-$65,822$65,822At / below entered requirement
-100%$0-$100,822-200.82%-$100,822$100,822At / below entered requirement

How the maintenance threshold is calculated

In this simplified long-margin model, account equity equals holdings value minus the outstanding debit. The modeled maintenance threshold is the holdings value where that equity equals the reader-entered maintenance percentage of holdings value.

Borrowed debit = holdings value - account equity
Gross leverage = holdings value ÷ account equity
Maintenance excess = account equity - holdings value × maintenance %
Maintenance threshold value = borrowed debit ÷ (1 - maintenance %)
Simple financing cost = debit × annual rate × days ÷ 365

With the default $200,000 of holdings and $100,000 of equity, the modeled debit is $100,000 and gross leverage is 2x. At a 30% entered maintenance requirement, the no-interest threshold is about $142,857, or roughly a 28.6% decline in holdings value from the starting level.

Where this calculator stops

This is not a brokerage margin calculator and does not estimate buying power, Regulation T initial margin, portfolio-margin offsets, security-specific haircuts, short-sale requirements, option margin, concentration charges, intraday rules, or liquidation priority. It also does not model deposits, withdrawals, dividends, taxes, commissions, changing interest rates, or different price moves across holdings.

Brokerage firms can impose house requirements above regulatory minimums, can change those requirements, and may liquidate positions without waiting for a customer to meet a margin call. Use the maintenance requirement shown by your broker when you want this page to approximate your current account rather than a hypothetical stress case.

For stop-based sizing before entering a stock position, use the Stock Position Size Calculator. For a beta-adjusted futures hedge estimate, use the Portfolio Hedge Calculator.

Margin-risk references