Skip to content

    Ultimate Oscillator: Formula, Bank Nifty Example and Settings

    Quick answer

    Ultimate Oscillator explained with a full Bank Nifty worked example. Exact formula, settings, and Indian F and O tax basics.

    19 June 2026
    14 min read
    2,693 words

    Key Takeaways

    • 1.The Ultimate Oscillator (UO) blends three lookbacks, normally 7, 14 and 28 bars, into one 0 to 100 line, so a single fast spike cannot whipsaw your signal the way it does with a plain 14 day RSI.
    • 2.The real formula weights the three averages 4, 2 and 1. The full equation is UO = 100 times (4 times Avg7 plus 2 times Avg14 plus Avg28) divided by 7.
    • 3.Larry Williams designed UO to trade divergence, not raw overbought and oversold. A textbook buy needs bullish divergence, UO below 30, then a break above the divergence high.
    • 4.On a worked Bank Nifty daily series below, the seven period buying pressure sum is 1,530 and true range sum is 2,250, and the finished oscillator reads 58.57, a neutral and mildly bullish value.
    • 5.On NSE, equity and index intraday signals can be tested on the 5 minute and 15 minute charts, but remember F and O profits are taxed as business income, not as capital gains.

    What the Ultimate Oscillator Actually Measures

    The Ultimate Oscillator was published by Larry Williams in 1976 to solve one specific problem with single period oscillators. A standard 14 period RSI reacts to whatever happened over its one lookback window, so a sharp one day move can throw it into overbought territory even when the larger trend is calm. UO answers this by computing momentum over three windows at once, a short 7 bar, a medium 14 bar and a long 28 bar, and then blending them so no single timeframe dominates.

    The building block is not price itself but buying pressure. For each bar, buying pressure asks how far the close finished above the true low of the move, where the true low is the lower of today's low and yesterday's close. That number is then divided by the true range of the bar. When closes keep finishing near the top of their ranges, buying pressure stays high and the oscillator rises. When closes keep slipping to the bottom of their ranges, buying pressure collapses and the line falls toward zero.

    Because the line is bounded between 0 and 100, traders read it like a momentum thermometer. The value matters less than its shape and its disagreement with price. A flat 55 reading tells you little, but a UO that carves a higher low while price carves a lower low is the divergence setup the indicator was built to catch.

    The Exact Formula, Step by Step

    Many guides stop after defining buying pressure and true range and never finish the calculation, which leaves you unable to verify a single number. Here is every step. First, for each bar, compute the prior close, then the true low as the minimum of the current low and the prior close, and the true high as the maximum of the current high and the prior close.

    • Buying Pressure (BP) = Close minus the lower of (today's Low, yesterday's Close).
    • True Range (TR) = the higher of (today's High, yesterday's Close) minus the lower of (today's Low, yesterday's Close).
    • Avg7 = sum of BP over 7 bars divided by sum of TR over 7 bars.
    • Avg14 = sum of BP over 14 bars divided by sum of TR over 14 bars.
    • Avg28 = sum of BP over 28 bars divided by sum of TR over 28 bars.
    • Ultimate Oscillator = 100 times (4 times Avg7 plus 2 times Avg14 plus Avg28) divided by 7.

    The divisor of 7 is simply the sum of the weights, that is 4 plus 2 plus 1. The short window gets the heaviest weight because Williams wanted the oscillator to respond to fresh momentum while still being anchored by the slower windows. Note one subtle point that trips people up, you average the sums of BP and TR, you do not average the daily BP divided by TR ratios. Summing first and dividing once is what gives UO its smoothness.

    Tip

    You need at least 28 completed bars before the first valid UO value exists, plus one more bar at the start to seed the prior close. On a daily Bank Nifty chart that is roughly six trading weeks of history before the line settles down.

    A Fully Worked Bank Nifty Example

    Numbers below are illustrative and rounded for teaching, not live quotes, but the arithmetic is exact and you can reproduce every figure. Take eight consecutive Bank Nifty daily bars. The first bar only supplies the seed prior close of 47,800. The next seven bars are the 7 period window. For each, we compute BP and TR using the rules above.

    BarHighLowClosePrior CloseBPTR
    148,10047,75048,05047,800300350
    248,20047,90048,15048,050250300
    348,05047,65047,70048,15050500
    447,80047,50047,75047,700250300
    547,90047,60047,88047,750280300
    648,05047,80048,00047,880200250
    748,15047,90048,10048,000200250

    Look at bar 3 to see why true range matters. Price gapped down from a 48,150 prior close to a 47,700 close. The true low is the lower of the 47,650 low and the prior close, so 47,650. BP is 47,700 minus 47,650, which is just 50, almost no buying pressure. TR is the true high of 48,150 minus the true low of 47,650, which is 500, a wide range. That single weak bar drags the short window down, exactly as it should.

    Now sum the columns. The seven BP values add to 1,530 and the seven TR values add to 2,250. So Avg7 equals 1,530 divided by 2,250, which is 0.6800. For the longer windows, assume the running sums over 14 bars are 2,880 of buying pressure against 6,000 of true range, giving Avg14 of 0.4800, and over 28 bars 5,040 against 12,000, giving Avg28 of 0.4200. These reflect a market that was weaker earlier and has firmed up recently.

    Plug the three averages into the weighted formula. UO equals 100 times (4 times 0.68 plus 2 times 0.48 plus 0.42) divided by 7. The numerator inside is 2.72 plus 0.96 plus 0.42, which is 4.10. Divide by 7 to get 0.5857, then multiply by 100. The finished Ultimate Oscillator reads 58.57. That is a neutral and mildly bullish value, well below the 70 overbought line and far above the 30 oversold line, so on its own it is not a trade. The signal would only arrive on a clean divergence or a cross of a level you have marked.

    Reading the Levels Without Fooling Yourself

    The conventional bands are 70 for overbought and 30 for oversold, but the original method is stricter than buying at 30 and selling at 70. Williams required a confirmed divergence before acting, which filters out most of the noise that destroys traders who treat any oscillator as a simple level cross. In a strong Bank Nifty rally the UO can sit above 70 for many sessions, and shorting every time it pokes above 70 will bleed your account through small stop outs.

    • Bullish setup, price prints a lower low, UO prints a higher low, UO is under 30 during the divergence, then UO breaks above the high it made during that divergence. The break is the trigger.
    • Bearish setup, price prints a higher high, UO prints a lower high, UO is above 70 during the divergence, then UO breaks below the low it made during that divergence.
    • Failure to confirm, if the divergence never resolves with a level break, there is no signal. A divergence alone is a warning, not an entry.

    For Indian index traders the practical takeaway is that UO works best as a timing filter on top of trend. Define the trend on a higher timeframe, then use UO divergence in the direction of that trend. Counter trend UO signals into a powerful Nifty or Bank Nifty move are the lowest probability trades you can take with this tool.

    Settings for NSE Stocks and Indices

    The default 7, 14 and 28 windows were chosen for daily charts and they remain the most robust choice for liquid NSE names like Reliance, HDFC Bank, TCS and Infosys, and for the Nifty 50 and Bank Nifty indices. They are also the settings most other traders watch, which matters because crowded levels create self fulfilling reactions. Resist the urge to over optimise these numbers on past data, because a setting that looks perfect on one stretch of Bank Nifty usually fails on the next.

    Timeframe choice matters more than tinkering with the periods. On a daily chart UO swings are slow and divergences are meaningful. On a 5 minute Bank Nifty chart for monthly expiry scalping, the same windows turn over far faster and produce many more signals, most of which are noise around the open and close. If you trade intraday, a 15 minute chart usually gives a cleaner UO than the 5 minute.

    Use caseSuggested chartPeriodsNote
    Swing trading NSE cash stocksDaily7, 14, 28Cleanest divergences, default and crowded
    Positional Nifty or Bank NiftyDaily or 4 hour7, 14, 28Pair with the prevailing trend
    Intraday index F and O15 minute7, 14, 28Skip the first 15 minutes after the open
    Fast expiry day scalping5 minute7, 14, 28Expect more false signals, tighten stops

    UO Versus RSI and Stochastic

    Traders almost always already use the RSI or the stochastic, so the fair question is what UO adds. The honest answer is that UO trades fewer signals but each one is better filtered against single bar noise. RSI is faster and gives more entries, which suits active intraday traders, while UO is slower and is built around divergence, which suits position and swing traders who want fewer, higher quality reversals.

    FeatureUltimate OscillatorRSIStochastic
    Lookbacks usedThree (7, 14, 28)One (usually 14)One plus smoothing
    Core ideaMulti timeframe buying pressureAverage gain vs lossClose vs recent range
    Main signalDivergence with level breakOverbought, oversold, divergenceK and D crossovers
    Noise resistanceHighMediumLow, very twitchy
    Signal frequencyLowMediumHigh

    A sensible combination on a daily Reliance or HDFC Bank chart is to use the trend from a moving average, the RSI for a first momentum read, and the UO purely to validate divergences before you commit capital. When RSI and UO both flag the same divergence at the same swing, the setup is far stronger than either alone.

    Turning a UO Signal Into a Trade, With the Rupee Math

    Say your daily Bank Nifty UO printed a bullish divergence near 28 and then broke above its divergence high, while spot sat near 48,100, matching our worked example. You decide to express the bullish view with options rather than futures to cap risk. These figures are illustrative. The Bank Nifty lot size is 30. You buy one weekly 48,200 call at a premium of 320 rupees per unit. Your outlay is 320 times 15, which is 4,800 rupees plus charges, and that premium is the absolute most you can lose.

    Assume the move plays out and Bank Nifty rallies, lifting that call from 320 to 480 over the next two sessions. Your gross gain is 480 minus 320, which is 160 rupees per unit, times the 15 lot, which is 2,400 rupees before costs. Now subtract realistic frictions. Securities Transaction Tax on options is charged at 0.1 percent of the premium on the sell side, brokerage at a flat 20 rupees per order on a discount broker plus exchange transaction charges, plus 18 percent GST on brokerage and on those exchange charges. Round trip costs on a single lot like this typically run in the region of 60 to 90 rupees, so a net profit near 2,320 to 2,340 rupees is realistic.

    Tax reminder

    Profit from futures and options is treated as business income in India and is taxed at your applicable slab rate, not at the 20 percent short term or 12.5 percent long term capital gains rates that apply to delivery equity. There is no 1.25 lakh exemption for F and O. Keep every contract note, because turnover and audit rules for F and O are strict. These numbers are illustrative and not a promise of returns.

    Limitations and Common Mistakes

    No oscillator predicts the future, and UO is no exception. In a strong directional Bank Nifty trend the line can stay pinned in overbought or oversold for a long time, and traders who fade every extreme get ground down. The slower nature of UO that makes its signals cleaner also makes it lag, so on fast expiry day moves it may confirm a divergence only after a large part of the swing is over.

    • Treating any cross of 30 or 70 as a trade. The original method requires divergence plus a level break, not a bare cross.
    • Averaging daily BP divided by TR ratios instead of summing BP and TR separately. This produces a wrong, jumpier line.
    • Running UO on illiquid small cap NSE stocks where wide gaps inflate true range and distort buying pressure.
    • Fading UO extremes against a powerful trend instead of trading divergences in the direction of the higher timeframe trend.
    • Forgetting that intraday UO on a 5 minute chart fires far more false signals than the daily, especially right after the 9:15 open.

    Use UO as one input in a checklist, never as a standalone system. Combine it with trend context, support and resistance, and disciplined position sizing, and log every trade in a structured journal so you can see whether your UO setups actually carry an edge on your instruments rather than assuming they do.

    Sources and Further Reading

    For authoritative data and further reading, refer to Zerodha Varsity, Investopedia, NSE Indices and NSE India. Always confirm current lot sizes, STT rates and contract specifications on the official source before you trade.

    Sources and Further Reading

    For authoritative data and further reading on this topic, refer to Zerodha Varsity, Investopedia, NSE Indices (Nifty Indices) and NSE India. Always confirm current rules, rates and contract specifications on the official source before you trade.

    Related Topics

    Ultimate OscillatorIndian stock markettechnical analysisNSEBSE

    Related Articles

    OneTradeJournal

    The trading journal built for Indian F&O traders. Track your trades, spot patterns, build discipline.

    • Log one trade a day by hand, on purpose
    • AI mentor finds your repeat mistakes
    • Behavioural analytics catch tilt early
    • Trading calendar with P&L heatmap
    • Pre-trade checklist flags risks
    Start journaling

    Yearly ₹2,499 · No broker credentials