On This Page
Key Takeaways
- A doji has little or no real body because its open and close are equal or nearly equal.
- This example classifies a positive-range candle as doji when its body occupies 5% or less of its range.
- Shadow length and location create long-legged, dragonfly, gravestone, and other doji variants.
- Measure the upper and lower shadows separately to locate the small body within the full range.
- Trend, support, resistance, volume, and the following price action provide the context for interpretation.
What is a doji candlestick?
A doji candlestick is a candle whose open and close are equal or nearly equal, so its real body is tiny or absent inside the period’s high-low range. The shadows show how far price traveled above and below that body, and the completed candle’s high and low give two clear levels for a range-break setup.
How to identify a doji: body ratio and shadows
For a positive range, divide |close − open| by high − low. This example uses a doji threshold of 5% or less.
The worked candle has O $40.02, H $41.20, L $39.60 and C $40.06. Its $0.04 body divided by the $1.60 range equals 2.5%, meeting the rule.
Upper shadow is $41.20 − $40.06 = $1.14. Lower shadow is $40.02 − $39.60 = $0.42. Body plus both shadows equals $1.60.
A four-price doji has O = H = L = C. Classify that zero-range case separately before dividing.
Formula
For high > low: body ratio = |close − open| / (high − low). This example uses body ratio ≤ 5%. Classify high = low separately before division.- An exact open-close match has a zero body ratio when the candle range is greater than zero.
- Apply the 5% rule to the four displayed candles, then compare their upper and lower shadows.
Worked Example
A stock opens at $40.02, trades as high as $41.20 and as low as $39.60, then closes at $40.06. A rule classifies candles with a body no larger than 5% of total range as doji.
- |$40.06 − $40.02| = $0.04 real body
- $41.20 − $39.60 = $1.60 total range
- $0.04 / $1.60 = 2.5% body ratio
The candle qualifies under the stated 5% rule because its 2.5% body ratio is small, while its long shadows show a much wider intraperiod range.
Types of doji: standard, long-legged, dragonfly and gravestone
| Shape | Body | Range | Body as Share of Range |
|---|---|---|---|
| Standard Example | $0.01 | $0.67 | 1.49% |
| Long-Legged Example | $0.04 | $1.60 | 2.50% |
| Dragonfly Example | $0.02 | $0.86 | 2.33% |
| Gravestone Example | $0.02 | $0.92 | 2.17% |
The long-legged example extends on both sides of its body. The Dragonfly and Gravestone put their bodies near opposite ends of the range. Their long shadows identify the side where price traveled furthest from the opening area.
Doji shape vs daily price change
A doji compares close with its own open. A session that gaps above the prior close can finish near its open and still record a large day-over-day gain.
Use the same interval and session definition when scanning a series. Read the complete OHLC values and classify the body from the selected numeric rule. For prices restricted to a fixed tick grid, one tick is the smallest positive open-close difference; zero is also possible.
How to trade a doji range break
Locate the doji at Support or Resistance. Mark its high and low, then choose a trade-above/below or close-above/below trigger.
Specify the entry, invalidation and target. Calculate the distance between the selected entry and stop reference, then size the position around that plan. Use Relative Volume to compare participation over matching observation windows.
The break of the doji’s range ends the balance; Options Flow shows which way the large orders in the ticker lean, and the Options Profit Calculator models each structure from that break to your target.
Limitations of the doji candlestick
- Take direction from the break of the doji’s range. A doji records a balanced period, and it carries the most weight after a prior move, at a level such as support or resistance.
- State the body threshold in the rule. This page uses 5%, while other sources and charting platforms use different limits, so the same candle can count as a doji on one screen and not on another.
- Fix the interval and session before scanning. The same price move can form a doji on a daily chart and none on an hourly chart, and extended-hours prices can change the open, close and range.
- Check the change from the prior close separately. The body compares the close with the candle’s own open, so a doji can sit on top of a large gap and a large day-over-day change.
Bottom line
A doji marks a period that closed near where it opened, and its high and low define the range to watch for a break. It carries the most weight at support or resistance after a clear move: state the body rule, wait for the break, and size the trade from the distance to the stop.
Clear answers
Frequently Asked Questions
Sources and Further Reading
How entries are sourced, calculated and updated: editorial methodology.