Back to Blog
Tutorials November 13, 2026

AI Candlestick Pattern Scanner for Doji Hammer Engulfing

Learn how an AI candlestick pattern scanner spots doji, hammer, and engulfing setups automatically, plus filters and risk rules to cut false signals.

By Trading AI Team

AI Candlestick Pattern Scanner for Doji Hammer Engulfing

Key Takeaways

  • Automatic candlestick detection is most reliable when you confirm patterns with trend context, nearby support resistance, and a volume or volatility filter.
  • A practical way to reduce false doji signals is to require the real body be under 10% of the candle range and occur after a 3 to 7 bar push.
  • AI candlestick recognition should be tuned by market and timeframe, because BTC 15m noise and AAPL daily structure produce different error rates.
  • Hammer and engulfing patterns perform better when the scanner also checks location, such as a hammer within 0.5 ATR of a prior swing low.
  • Treat any candlestick pattern scanner output as a trade idea, then apply a fixed stop rule (like 1.2 ATR) and minimum 2R target.

Candlestick patterns are simple, but spotting them consistently across dozens of charts is not. An AI candlestick pattern scanner can do the heavy lifting—if you know what it’s actually detecting and how to filter the junk.

What an AI candlestick pattern scanner really detects

Most traders assume pattern scanning is “visual,” but scanners work from numbers: open, high, low, close, sometimes volume. AI candlestick recognition typically means the app classifies candles using rules plus statistical/ML scoring to decide whether a pattern is “close enough.”

The three pattern families this tutorial focuses on

  • Doji: indecision candles where open and close are near each other.
  • Hammer / Inverted Hammer: rejection candles with a long wick and small body, ideally after a decline.
  • Engulfing (bullish/bearish): a candle whose real body “engulfs” the prior candle’s body, often signaling a momentum shift.

Actionable tip: Before trusting any automatic candlestick detection, open the scanner settings (or documentation) and confirm whether it uses real body (|close-open|) or full range (high-low) for thresholds—this changes results materially.

Why scanners disagree on the same chart

Two scanners can look at the same BTC chart and disagree because they use different thresholds:

  • Doji body size allowed: 5% vs 15% of range
  • Wick length requirements for hammer: 2x body vs 3x body
  • Engulfing definition: body-only engulf vs including wicks

If you’re comparing “candlestick AI free” tools, this is the first thing to check: free scanners often use fixed thresholds with no market-specific tuning.

Actionable tip: Pick one definition set and stick to it for a month of trading, so your stats aren’t polluted by changing pattern rules.

Pattern rules that matter for doji hammer and engulfing

You don’t need institutional math, but you do need crisp rules. Below are trader-practical definitions you can use to validate what your scanner flags.

Doji detection rules you can audit

A workable doji rule:

  • Real body ≤ 10% of candle range (high-low)
  • Candle range ≥ 0.8x the 14-period ATR (optional, but helpful to avoid tiny “dojis”)
  • Occurs after a directional push of 3–7 candles (context filter)

Example: EUR/USD (1H)
If price rallies 40–60 pips over 5 hours and then prints a doji with a 2-pip body and 25-pip range near a prior daily level, that’s a valid “decision point.” A random doji mid-range is usually noise.

Actionable tip: Require the doji high/low to touch a key level (prior day high/low, weekly pivot, or a visible swing) before acting.

Hammer detection rules that reduce false positives

A classic hammer checklist:

  • Lower wick ≥ 2x real body
  • Upper wick small (often ≤ real body)
  • Closes in the upper 25% of the range
  • Appears after a decline (at least 3 lower closes or a move of 1 ATR down)

Example: AAPL (Daily)
If AAPL drops for 4 sessions, tags a prior demand zone, and prints a hammer where the wick is 3x the body, that’s meaningful rejection. If the same hammer prints after a strong uptrend, it’s often just profit-taking.

Actionable tip: Add a location rule: only take hammers that form within 0.5 ATR of a prior swing low or a marked support zone.

Engulfing rules that traders should actually use

A strict bullish engulfing rule:

  • Current candle body opens below prior close and closes above prior open (body engulfs body)
  • Current body size ≥ 1.2x prior body (strength filter)
  • Better if it breaks above the prior candle high (momentum confirmation)

Example: ETH (4H)
After a down leg, ETH prints a small red candle, then a large green candle that closes above the prior open and above the prior high—this is the kind of engulfing that tends to follow through.

Actionable tip: Don’t trade engulfing patterns that occur inside a tight range; require a close beyond the range midpoint or a micro-structure break.

How to set up automatic candlestick detection for real trading

The best use of a scanner is not “take every signal.” It’s “surface candidates,” then apply a repeatable checklist.

Step 1: Choose your market and timeframe on purpose

Pattern edge changes by instrument and timeframe:

  • BTC/USDT 15m: lots of false positives due to noise and wicks.
  • ETH 4H: cleaner swings, still active enough for multiple setups weekly.
  • AAPL Daily: fewer signals, often higher quality, but slower feedback loop.
  • EUR/USD 1H: decent balance; watch session effects (London/NY).

Actionable tip: Start with one market + one timeframe for 20 trades before expanding; otherwise you won’t know if the scanner settings are helping.

Step 2: Add two filters that do most of the work

If your app supports filters, prioritize these:

  1. Trend filter: 20 EMA vs 50 EMA, or price vs 200 EMA
    • Bullish patterns only when price is above 200 EMA, bearish only below (simple, effective).
  2. Volatility filter: ATR rising or ATR above a threshold
    • Patterns in dead volatility regimes often fail because there’s no follow-through.

Actionable tip: For engulfing trades, require ATR(14) to be at least 80% of its 50-period average; it’s a quick way to avoid sleepy markets.

Step 3: Build a “pattern plus trigger” rule

A scanner finds shapes; your job is to define a trigger:

  • Doji trigger: trade the break of the doji high/low (with a buffer like 0.1 ATR).
  • Hammer trigger: buy stop above hammer high; invalidation below hammer low.
  • Engulfing trigger: enter at close (aggressive) or on a pullback to 50% of the engulfing candle (conservative).

Actionable tip: Use a fixed “no trade” rule: if the next candle closes back inside the pattern’s range, skip the setup.

Image1

Practical examples on BTC ETH AAPL and EUR USD

Below are examples of how you’d translate scanner hits into structured trades. The numbers are rules-based so you can backtest them.

Example 1: BTC doji at resistance with break trigger

Setup:

  • Market: BTC/USDT 1H
  • Condition: price rallies into a prior swing high and prints a doji (body ≤ 10% of range)
  • Filter: RSI(14) > 65 or distance from 20 EMA > 1.0 ATR (stretched)

Trade plan:

  • Entry: sell stop 0.1 ATR below doji low
  • Stop: 0.2 ATR above doji high (or above level)
  • Target: 2R, or next support zone

Actionable tip: If BTC is during a major news window (CPI/FOMC), widen the buffer to 0.2 ATR or skip; doji breaks get messy in headline spikes.

Example 2: ETH hammer with location and ATR stop

Setup:

  • Market: ETH/USDT 4H
  • Condition: hammer forms within 0.5 ATR of a prior swing low
  • Filter: 20 EMA still sloping down (countertrend), so demand stronger confirmation

Trade plan:

  • Entry: buy stop above hammer high
  • Stop: 1.2 ATR below entry (or below hammer low, whichever is wider)
  • Take profit: scale 50% at 1R, rest at 2.5R

Actionable tip: Countertrend hammers work better with partial profits; the first bounce is common, the trend reversal is optional.

Example 3: AAPL bullish engulfing with trend alignment

Setup:

  • Market: AAPL Daily
  • Condition: bullish engulfing after a pullback in an uptrend
  • Filter: price above 200 EMA and engulfing candle closes above the prior 5-day midpoint

Trade plan:

  • Entry: at close or next day’s open
  • Stop: below engulfing low
  • Target: previous swing high; if that’s less than 1.8R, skip

Actionable tip: For equities, check the earnings calendar; engulfing signals inside 3 trading days of earnings have a different risk profile.

Example 4: EUR USD bearish engulfing at session high

Setup:

  • Market: EUR/USD 1H
  • Condition: bearish engulfing forms after London push into prior day high
  • Filter: volume proxy (tick volume) above 20-period average on engulfing candle

Trade plan:

  • Entry: sell at close
  • Stop: above engulfing high + 2 pips
  • Target: VWAP or mid-range; trail remainder using 20 EMA

Actionable tip: If the engulfing candle is more than 1.8 ATR, reduce size; oversized candles often retrace before continuation.

Pros and cons of AI candlestick recognition for retail traders

Used well, scanners save time and standardize execution. Used blindly, they encourage overtrading.

Pros that actually show up in performance

  • Consistency: the same rules applied every time, even when you’re tired.
  • Coverage: scanning 50 crypto pairs or a stock watchlist becomes realistic.
  • Faster journaling: you can tag trades by pattern type and measure expectancy.

Actionable tip: Track results by pattern and context tag (trend vs countertrend, at support vs mid-range). Most “pattern edges” live in the context, not the shape.

Cons you need to price in

  • False positives: especially on low timeframes and in choppy ranges.
  • Definition drift: if the tool updates thresholds, your historical results may not match.
  • Overfitting risk: tuning settings until they match the last month, then failing forward.

Actionable tip: Lock your settings for a fixed sample (like 50 trades) before changing anything; treat changes like strategy revisions, not tweaks.

What to look for in a scanner tool

If you’re evaluating a scanner (including “candlestick AI free” options), prioritize:

  • Adjustable thresholds (body %, wick ratio, engulfing strength)
  • Context filters (trend, volume, ATR, level proximity)
  • Alerts + backtestable logs (time, ticker, timeframe, pattern type)

Tools and features to consider:

Actionable tip: If the tool can’t export a signal list (CSV/log), it’s hard to validate; validation is the whole point.

A simple scanner based strategy you can backtest

Here’s a compact ruleset that blends scanning with confirmation. It’s not “magic,” but it’s testable.

The rules

  1. Market: pick one (e.g., ETH/USDT 4H).
  2. Scanner: alert on bullish engulfing and hammers only.
  3. Trend filter: only take longs when price is above the 200 EMA.
  4. Location filter: signal candle must be within 0.75 ATR of the 20 EMA (avoid chasing).
  5. Entry: buy stop above signal high by 0.1 ATR.
  6. Stop: below signal low (or 1.2 ATR, whichever is wider).
  7. Exit: take 50% at 1R, remainder at 2.5R or trail with 20 EMA close.

Why this works better than “pattern only”

  • The 200 EMA filter removes most countertrend traps.
  • The ATR buffer reduces “nick” entries that get wicked out.
  • Scaling out improves equity curve stability because not every signal trends.

Actionable tip: If your win rate is under 40%, raise the quality bar by requiring the engulfing candle body ≥ 1.5x the prior candle body.

Frequently Asked Questions

What is the best timeframe for candlestick pattern scanners

The best timeframe is usually 1H to Daily because patterns have cleaner structure and fewer random wicks than 1m to 15m charts. Crypto traders often prefer 4H for a balance of signal quality and frequency. If you trade lower timeframes, add ATR and trend filters to control noise.

How accurate is automatic candlestick detection in choppy markets

Accuracy drops sharply in ranges because doji and small engulfing patterns appear constantly without follow-through. The fix is to require context like level proximity, a trend filter, and minimum candle size versus ATR. If the tool supports it, disable signals when ATR is below its 50-period average.

Can I use candlestick AI free tools for real trading

Yes, but only if you can audit the pattern definitions and keep them consistent over time. Many free scanners lack adjustable thresholds and context filters, which increases false positives. Use them for idea generation, then apply strict entry and stop rules manually.

How do I confirm a doji hammer or engulfing signal

Confirm with a trigger such as a break of the pattern high/low, plus a context check like support resistance alignment. Add one objective filter: trend (200 EMA) or volatility (ATR rising). If confirmation fails on the next candle close, skip the trade.

References

  • Steve Nison, Japanese Candlestick Charting Techniques.
  • TradingView public documentation on candlestick patterns and scripting concepts.

AI Candlestick Pattern Detector: How It Actually Works I trained an AI Model to Detect Trading Candlesticks (from scratch using ViTs) Candlestick Patterns and AI: A Quicker Review Workflow | Longbridge Crypto Candlestick Pattern Screener & Live Scanner GitHub - Narfinsel/Candlestick-Pattern-Scanner: CandlestickPatternScanner is a utility class that helps Expert Advisors and trading bots to efficiently detect reversal · GitHub

External References

#AI#candlesticks#scanner#patterns
Trading AI Logo Trading AI

Start trading with artificial intelligence

Join 50,000+ traders already using Trading AI for their daily analysis

Trading AI is an analysis tool. It does not constitute financial advice.

Analysis by type

Product

Download

Legal