VALYNOXSTRATEGY RESEARCH TECHNOLOGY
AlphaPrimeAlphaPrime

Indicator Encyclopedia · Candlestick patterns

Hammer candlestick: shape, context and strategy ideas

A hammer is a single candle with a small body near the top of its range and a long lower shadow. It records a bar in which sellers pushed price well down, then buyers pulled it most of the way back before the close. When it appears after a decline, traders read it as a sign that lower prices were rejected and selling is losing force, and they usually wait for the next candle to close above the hammer before treating it as a turn. This page covers how to read it, which context changes its meaning, and how a strategy generator can check whether it adds anything on your contract.

What it describes

A hammer describes the shape of one bar. The real body, the distance between open and close, is small compared with recent bars, and it sits near the top of the bar's range. Below it hangs a lower shadow that is clearly longer than the body, while the upper shadow is very short or absent. The colour of the body matters less than the proportions: what defines the pattern is that price travelled down a long way inside the bar and finished near where it started.

That shape tells a short story. Sellers were in control for part of the bar and drove price to a new low, but they could not hold it. By the close, buyers had absorbed the selling and pushed price back up. A hammer does not say the decline is over; it says that at this moment, lower prices were rejected.

Because the pattern is defined relative to recent bars, the same absolute price move can be a hammer in a quiet market and an ordinary bar in a volatile one. Most definitions also look at where the body sits against the previous bar, so that the candle appears near a recent low rather than in the middle of nowhere.

How context changes the meaning

Context does most of the work. A hammer after a sustained decline, near a level where price has turned before, is read very differently from the same shape in the middle of a range. Many traders ignore hammers that appear without a prior move down, because there is no selling pressure for the candle to reject.

On intraday futures charts the pattern appears often, and many occurrences are noise: a brief sweep below a round number that is filled within the bar. Session boundaries matter too. A bar that includes the open can show a long lower shadow simply because of an opening gap, which is a different event from buyers stepping in during the session.

Confirmation is a common habit. Rather than acting on the hammer bar itself, traders wait for the next bar to close above the hammer's high or body before treating the rejection as real. This costs some of the move but filters out hammers that are immediately followed by new lows.

Pairing it with other indicator families

A hammer is a statement about one bar, so it pairs well with tools that describe the larger picture. A trend measure such as a moving average or ADX says whether there is a decline to reverse or a trend to rejoin, and the hammer marks the bar where the turn is attempted.

Momentum oscillators add a second view of exhaustion. A hammer that forms while RSI or the Stochastic oscillator is stretched to the downside describes the same event from two angles: price rejected lower levels, and the recent decline had already run far. Requiring both is stricter and produces fewer signals.

Volume, where the data has it, helps separate a real rejection from a thin-market wick. A hammer on a bar with heavier volume than usual suggests that many participants took part in the reversal inside the bar, while a long shadow on light volume can be a single order passing through an empty book.

In AlphaPrime

In the AlphaPrime strategy generator, the hammer is one of the conditions in the built-in candlestick family. The generator can use it as an entry trigger, combine it with trend, momentum, volatility and session rules, or use its absence as a filter, so the same idea appears as several candidates that are backtested side by side.

That makes it possible to ask a concrete question: on this contract and timeframe, does requiring a hammer improve a rule, or does it only reduce the number of trades? Out-of-sample validation removes combinations that only looked good in one stretch of history, and the result is shown whether the pattern helps or not.

Combinations that pass validation can be exported as strategy code for your trading platform, with the candlestick condition written out alongside the other rules, so you can read exactly what the strategy checks.

Common ways to use it

Reversal entry

Hammer after a decline

Allow a long entry only when a hammer appears after price has fallen for a while, often measured by price sitting below a falling moving average. The hammer marks the attempt to turn; the moving average defines that there was something to turn from.

Pullback entry

Hammer inside an uptrend

In an established uptrend, a hammer at the end of a pullback can mark the point where buyers return. Traders often require the pullback to reach a band such as the lower Bollinger Band or a short-term average before accepting the signal.

Risk placement

Stop below the shadow

The low of the lower shadow is a natural reference for a protective stop, because a move below it means the rejected prices have been accepted after all. The distance is often checked against ATR so the stop is neither inside normal noise nor unreasonably wide.

FAQ

Does the colour of a hammer's body matter?

Traditional definitions accept either colour, because the shape is what records the rejection. Some traders give more weight to a hammer that closes above its open. Whether that distinction matters on your market is a question a backtest can answer more reliably than a rule of thumb.

What is the difference between a hammer and a hanging man?

The shape is the same. The name depends on context: after a decline it is called a hammer, after a rally a hanging man. That is why the surrounding trend is part of reading the pattern, and why it is usually combined with a trend measure.

Can a strategy that uses the hammer run on my trading platform?

Yes. When a combination that includes the hammer passes validation, it is exported as strategy code for your platform, with the pattern condition included, so you can review it, simulate it and decide whether to use it.