# Trading Filters Guide

### 📋 Overview

RedFox Copier Pro includes multiple filtering layers to control which signals are executed. You can filter by symbol, trading hours, days of week, and signal content. This ensures you only trade what fits your strategy and schedule.

**Filter Categories:**

1. **Symbol Filters** - Which instruments to trade
2. **Time Filters** - When to trade (hours & days)
3. **Content Filters** - What text patterns to allow/block

***

### 🎯 Symbol Filters

#### **1. EnableListSymbol**

```
EnableListSymbol = true | false
```

**Controls whether symbol filtering is active.**

***

#### **false** (Default - All Symbols)

**Behavior:** EA trades all symbols from signals.

**Example:**

```
Signals received:
- EURUSD BUY ✅
- XAUUSD BUY ✅
- GBPJPY SELL ✅
- US30 BUY ✅

All symbols are traded
```

**When to use:**

* Trust all signal provider's instruments
* Want maximum diversification
* No symbol preferences

***

#### **true** (Symbol Whitelist Active)

**Behavior:** EA only trades symbols in `ListSymbol` setting.

**Example:**

```
ListSymbol = "EURUSD,GBPUSD,XAUUSD"

Signals received:
- EURUSD BUY ✅ (in list)
- GBPUSD SELL ✅ (in list)
- USDJPY BUY ⚠️ (not in list, blocked)
- XAUUSD BUY ✅ (in list)
```

**When to use:**

* Focus on specific instruments
* Avoid high-spread pairs
* Limit to pairs you understand
* Broker doesn't offer all symbols

***

#### **2. ListSymbol**

```
ListSymbol = "EURUSD,GBPUSD,XAUUSD"  // Comma-separated list
```

**Defines which symbols to trade (when EnableListSymbol = true).**

***

#### **Configuration Examples:**

**Major Forex Only:**

```
EnableListSymbol = true
ListSymbol = "EURUSD,GBPUSD,USDJPY,USDCHF"
```

**Gold + EUR Pairs:**

```
EnableListSymbol = true
ListSymbol = "XAUUSD,EURUSD,EURGBP,EURJPY"
```

**Indices Only:**

```
EnableListSymbol = true
ListSymbol = "US30,SPX500,NAS100,GER40"
```

**Mixed Portfolio:**

```
EnableListSymbol = true
ListSymbol = "EURUSD,GBPUSD,XAUUSD,BTCUSD,US30"
```

**Important:**

* Use **exact** broker symbol names (check Market Watch)
* No spaces after commas: `"EUR,GBP"` not `"EUR, GBP"`
* Case-sensitive on some brokers
* Include suffix if broker requires (e.g., `EURUSDm`, `XAUUSD.`)

***

#### **Symbol Suffix Handling**

**Problem:** Brokers add suffixes to symbols (EURUSD → EURUSDm, XAUUSD.)

**Solution:** EA automatically tries multiple suffix variations.

**Settings:**

```
SymbolsEnd = ""  // Your broker's suffix (if any)
```

**Examples:**

**No Suffix (Standard):**

```
SymbolsEnd = ""
Signal: EURUSD
EA opens: EURUSD ✅
```

**With Suffix (ECN Broker):**

```
SymbolsEnd = "m"
Signal: EURUSD
EA opens: EURUSDm ✅
```

**Auto-Detection:** EA tries these variations automatically:

```
Signal: EURUSD
EA tries:
1. EURUSD
2. EURUSDm
3. EURUSD.
4. EURUSDpro
5. EURUSD_
6. [other common suffixes]

Uses first match found in Market Watch
```

**Best Practice:** Leave `SymbolsEnd = ""` and let EA auto-detect.

***

### ⏰ Time Filters

#### **3. EnableTimeFilter**

```
EnableTimeFilter = true | false
```

**Controls whether time-based filtering is active.**

***

#### **false** (Default - 24/7 Trading)

**Behavior:** EA trades any time a signal is received.

**When to use:**

* Automated 24/7 trading
* Signal provider has good timing
* No schedule restrictions

***

#### **true** (Time Filter Active)

**Behavior:** EA only trades during specified hours and days.

**When to use:**

* Avoid high-spread hours (rollover, news)
* Trade only London/NY sessions
* Weekend/holiday restrictions
* Personal trading schedule

***

#### **4. StartHour / EndHour**

```
StartHour = 8   // Trading starts at 08:00 (broker time)
EndHour = 20    // Trading ends at 20:00 (broker time)
```

**Defines trading hours (24-hour format, broker server time).**

***

#### **Configuration Examples:**

**London + NY Session (Full Overlap):**

```
EnableTimeFilter = true
StartHour = 8   // 08:00
EndHour = 20    // 20:00
// Covers 8 AM - 8 PM (most liquid hours)
```

**NY Session Only:**

```
StartHour = 13  // 13:00 (1 PM)
EndHour = 22    // 22:00 (10 PM)
```

**Asian Session:**

```
StartHour = 0   // 00:00 (midnight)
EndHour = 9     // 09:00 (9 AM)
```

**Avoid Rollover (Skip 11 PM - 1 AM):**

```
StartHour = 1   // 01:00
EndHour = 23    // 23:00
// Skips 11 PM - 1 AM high-spread period
```

**Important Notes:**

* Times are in **broker server time** (check MT4 market watch)
* Most brokers use GMT+2/GMT+3 (Europe time)
* Convert your local time to broker time!

***

#### **Example Timeline:**

```
Configuration:
StartHour = 8
EndHour = 18

Signal Timeline (Broker Time):
07:30 - Signal received ⚠️ (before 08:00, blocked)
08:15 - Signal received ✅ (within hours, executed)
12:00 - Signal received ✅ (executed)
18:30 - Signal received ⚠️ (after 18:00, blocked)
```

**EA Logs:**

```
⚠️ Signal blocked by time filter
Current Time: 07:30
Allowed Hours: 08:00 - 18:00
Reason: Outside trading hours
```

***

#### **5. StartDay / EndDay**

```
StartDay = 1  // Monday (1 = Monday, 7 = Sunday)
EndDay = 5    // Friday
```

**Defines trading days (1=Mon, 2=Tue, 3=Wed, 4=Thu, 5=Fri, 6=Sat, 7=Sun).**

***

#### **Configuration Examples:**

**Weekdays Only (Avoid Weekend Gaps):**

```
EnableTimeFilter = true
StartDay = 1  // Monday
EndDay = 5    // Friday
// Trades Mon-Fri only
```

**Exclude Friday (Avoid Weekend Risk):**

```
StartDay = 1  // Monday
EndDay = 4    // Thursday
// Trades Mon-Thu, closes all before Friday
```

**Full Week (Including Weekend):**

```
StartDay = 1  // Monday
EndDay = 7    // Sunday
// Trades any day (if broker offers weekend trading)
```

**Mid-Week Only:**

```
StartDay = 2  // Tuesday
EndDay = 4    // Thursday
// Avoid Monday open volatility and Friday close
```

***

#### **Combined Time & Day Filter Example:**

**Professional Setup (London Session, Weekdays):**

```
EnableTimeFilter = true
StartHour = 8    // 08:00
EndHour = 17     // 17:00
StartDay = 1     // Monday
EndDay = 5       // Friday

Result:
✅ Monday 10:00 - Allowed
✅ Wednesday 15:00 - Allowed
⚠️ Friday 20:00 - Blocked (after 17:00)
⚠️ Saturday 12:00 - Blocked (weekend)
⚠️ Tuesday 06:00 - Blocked (before 08:00)
```

***

### 🔍 Content Filters (Whitelist/Blacklist)

#### **6. EnableWhitelist**

```
EnableWhitelist = true | false
```

**Controls whether signal text must contain specific keywords.**

***

#### **false** (Default - No Content Filter)

**Behavior:** All signal text formats are accepted.

**When to use:**

* Trust all signal provider's messages
* No specific content requirements

***

#### **true** (Whitelist Active)

**Behavior:** Signal text must contain at least one keyword from `Whitelist`.

**Use Cases:**

* Only trade specific signal types
* Filter by strategy name
* Require specific indicators mentioned

***

#### **7. Whitelist**

```
Whitelist = "PREMIUM,VIP,CONFIRMED"  // Comma-separated keywords
```

**Signal must contain at least ONE of these keywords to be executed.**

***

#### **Configuration Examples:**

**VIP Signals Only:**

```
EnableWhitelist = true
Whitelist = "VIP,PREMIUM"

Signal 1: "🔥 VIP Signal: EURUSD BUY" ✅ (contains "VIP")
Signal 2: "EURUSD BUY" ⚠️ (no keyword, blocked)
Signal 3: "PREMIUM Trade: GBPUSD SELL" ✅ (contains "PREMIUM")
```

**Confirmed Setups Only:**

```
EnableWhitelist = true
Whitelist = "CONFIRMED,STRONG SETUP,HIGH PROBABILITY"

Signal 1: "CONFIRMED: XAUUSD BUY" ✅
Signal 2: "Possible EURUSD trade" ⚠️ (not confirmed)
```

**Specific Strategy:**

```
EnableWhitelist = true
Whitelist = "BREAKOUT,TREND FOLLOW"

Signal 1: "BREAKOUT Signal - GBPUSD" ✅
Signal 2: "Scalp trade EURUSD" ⚠️ (wrong strategy)
```

**Multiple Channels (Filter by Source):**

```
EnableWhitelist = true
Whitelist = "CHANNEL-A,CHANNEL-B"

// Only signals tagged with channel name are executed
```

***

#### **8. EnableBlacklist**

```
EnableBlacklist = true | false
```

**Controls whether certain keywords block signals.**

***

#### **false** (Default - No Blacklist)

**Behavior:** No text-based blocking.

***

#### **true** (Blacklist Active)

**Behavior:** Signal is blocked if it contains ANY keyword from `Blacklist`.

**Use Cases:**

* Avoid risky setups
* Skip specific instruments
* Filter out test signals
* Block experimental strategies

***

#### **9. Blacklist**

```
Blacklist = "TEST,DEMO,RISKY"  // Comma-separated keywords
```

**Signal is blocked if it contains ANY of these keywords.**

***

#### **Configuration Examples:**

**Avoid Test Signals:**

```
EnableBlacklist = true
Blacklist = "TEST,DEMO,PRACTICE"

Signal 1: "TEST - EURUSD BUY" ⚠️ (contains "TEST", blocked)
Signal 2: "EURUSD BUY" ✅ (no blacklist word)
```

**Skip Risky Trades:**

```
EnableBlacklist = true
Blacklist = "RISKY,HIGH RISK,AGGRESSIVE,YOLO"

Signal 1: "RISKY TRADE: GBPJPY" ⚠️ (blocked)
Signal 2: "Conservative: EURUSD" ✅
```

**Avoid Specific Pairs (Alternative to Symbol Filter):**

```
EnableBlacklist = true
Blacklist = "JPY,EXOTIC,CRYPTO"

Signal 1: "USDJPY BUY" ⚠️ (contains "JPY")
Signal 2: "EURUSD BUY" ✅
```

**Filter News Trades:**

```
EnableBlacklist = true
Blacklist = "NEWS,NFP,FOMC,PENDING"

Signal 1: "NEWS Trade - EURUSD" ⚠️ (contains "NEWS")
Signal 2: "Technical Setup - GBPUSD" ✅
```

***

#### **Whitelist + Blacklist Combined:**

**Example: Only VIP, But Skip Risky**

```
EnableWhitelist = true
Whitelist = "VIP,PREMIUM"

EnableBlacklist = true
Blacklist = "RISKY,NEWS"

Signal 1: "VIP Signal: EURUSD BUY" ✅ (VIP + no blacklist)
Signal 2: "VIP RISKY: GBPJPY" ⚠️ (VIP but contains RISKY, blocked!)
Signal 3: "EURUSD BUY" ⚠️ (no VIP keyword)
Signal 4: "PREMIUM NEWS: XAUUSD" ⚠️ (PREMIUM but contains NEWS)
```

**Logic:**

1. Check whitelist: Must contain keyword
2. Check blacklist: Must NOT contain keyword
3. Both must pass for signal to execute

***

### 💼 Real-World Configuration Examples

#### **Example 1: Conservative Trader**

**Goal:** Only major pairs, London session, weekdays only.

**Configuration:**

```
// Symbol Filter
EnableListSymbol = true
ListSymbol = "EURUSD,GBPUSD,USDCHF"

// Time Filter
EnableTimeFilter = true
StartHour = 8
EndHour = 17
StartDay = 1
EndDay = 5

// Content Filter
EnableWhitelist = true
Whitelist = "CONFIRMED,LOW RISK"
EnableBlacklist = false
```

**Result:** Very selective trading, only clean setups during optimal hours.

***

#### **Example 2: Gold Specialist**

**Goal:** Only Gold, NY session, avoid news.

**Configuration:**

```
// Symbol Filter
EnableListSymbol = true
ListSymbol = "XAUUSD"

// Time Filter
EnableTimeFilter = true
StartHour = 13  // NY open
EndHour = 22    // NY close
StartDay = 1
EndDay = 5

// Content Filter
EnableWhitelist = false
EnableBlacklist = true
Blacklist = "NEWS,NFP,FOMC,CPI"
```

**Result:** Focused Gold trading, avoids high-impact news volatility.

***

#### **Example 3: Premium Signals Only**

**Goal:** Only VIP signals, any time, any symbol.

**Configuration:**

```
// Symbol Filter
EnableListSymbol = false  // All symbols

// Time Filter
EnableTimeFilter = false  // 24/7

// Content Filter
EnableWhitelist = true
Whitelist = "VIP,PREMIUM,GOLD SIGNAL"
EnableBlacklist = false
```

**Result:** Maximum flexibility but only premium tier signals.

***

#### **Example 4: Avoid Volatility**

**Goal:** Trade major pairs, avoid news and risky setups, avoid Friday.

**Configuration:**

```
// Symbol Filter
EnableListSymbol = true
ListSymbol = "EURUSD,GBPUSD,USDCHF,AUDUSD"

// Time Filter
EnableTimeFilter = true
StartHour = 8
EndHour = 20
StartDay = 1
EndDay = 4  // Monday-Thursday only

// Content Filter
EnableBlacklist = true
Blacklist = "NEWS,RISKY,AGGRESSIVE,VOLATILE,NFP,FOMC"
```

**Result:** Safe, conservative trading avoiding high-risk periods and setups.

***

#### **Example 5: Full Diversification**

**Goal:** Trade everything (maximum signals).

**Configuration:**

```
// Symbol Filter
EnableListSymbol = false

// Time Filter
EnableTimeFilter = false

// Content Filter
EnableWhitelist = false
EnableBlacklist = false
```

**Result:** EA executes every signal received (maximum exposure).

***

### ⚠️ Common Mistakes

#### ❌ **Mistake 1: Wrong Broker Symbol Names**

**Bad:**

```
ListSymbol = "EURUSD,XAUUSD"
Broker symbols: EURUSDm, XAUUSD.
// Result: No match, no trades!
```

**Good:**

```
Check Market Watch, use exact names:
ListSymbol = "EURUSDm,XAUUSD."
// Or use SymbolsEnd for auto-suffix
```

***

#### ❌ **Mistake 2: Time Zone Confusion**

**Bad:**

```
Your Time: 9 AM EST
Broker Time: 4 PM GMT+3
StartHour = 9  // Thinks this is broker time
// Result: Actually trading at 4 PM your time!
```

**Good:**

```
Convert to broker time:
Your 9 AM EST = 4 PM broker time
StartHour = 16
```

***

#### ❌ **Mistake 3: Whitelist + Blacklist Conflict**

**Bad:**

```
Whitelist = "VIP"
Blacklist = "VIP-TEST"

Signal: "VIP-TEST Signal"
// Contains "VIP" (whitelist pass) AND "VIP-TEST" (blacklist block)
// Result: Blocked (blacklist wins)
```

**Good:** Use precise keywords without overlap.

***

#### ❌ **Mistake 4: Too Restrictive Filters**

**Bad:**

```
EnableListSymbol = true
ListSymbol = "EURUSD"  // Only 1 symbol

EnableTimeFilter = true
StartHour = 14
EndHour = 16  // Only 2 hours

EnableWhitelist = true
Whitelist = "SUPER-VIP"  // Rare keyword

// Result: Almost no signals execute!
```

**Good:** Balance filters with signal frequency.

***

#### ❌ **Mistake 5: Spaces in Lists**

**Bad:**

```
ListSymbol = "EURUSD, GBPUSD, XAUUSD"  // Spaces after commas
// May cause parsing issues
```

**Good:**

```
ListSymbol = "EURUSD,GBPUSD,XAUUSD"  // No spaces
```

***

### ✅ Best Practices

#### ✅ **1. Start Permissive, Then Restrict**

**Week 1:**

```
All filters OFF
// See what signals come in
```

**Week 2:**

```
Add symbol filter (focus on profitable pairs)
```

**Week 3:**

```
Add time filter (optimize for best hours)
```

**Week 4:**

```
Add content filters if needed
```

***

#### ✅ **2. Monitor Filter Logs**

EA logs blocked signals:

```
⚠️ Signal blocked by symbol filter: USDJPY
⚠️ Signal blocked by time filter: 22:30
⚠️ Signal blocked by whitelist: No keyword found
```

Review logs weekly:

* Missing good trades? Relax filters
* Too many bad trades? Tighten filters

***

#### ✅ **3. Match Filters to Strategy**

**Scalping:**

```
EnableTimeFilter = true (high liquidity hours only)
EnableListSymbol = true (low spread pairs only)
```

**Swing Trading:**

```
EnableTimeFilter = false (entry timing less critical)
EnableListSymbol = true (focus on trending pairs)
```

**News Trading:**

```
Blacklist = "NEWS,NFP"  // Avoid (or whitelist for specialists)
```

***

#### ✅ **4. Test Filter Combinations**

* Run on demo with different configurations
* Compare performance (profit, drawdown, trade count)
* Find optimal balance

**Example Test:**

```
Week 1: All symbols, all time
Week 2: Major pairs only, all time
Week 3: Major pairs, London+NY only
Week 4: Major pairs, London+NY, VIP only

Compare results → Choose best
```

***

#### ✅ **5. Document Your Filters**

```
Filter Configuration Notes:
Date: 2024-10-28

Symbols: EURUSD, GBPUSD, XAUUSD (low spread, liquid)
Hours: 08:00-20:00 broker time (London+NY overlap)
Days: Mon-Thu (avoid Friday risk)
Content: VIP only (premium signals)

Reason: Focus on high-quality setups during optimal hours
Review Date: 2024-11-15
```

***

### 🔍 EA Logging Examples

**Symbol Filter Block:**

```
⚠️ SIGNAL BLOCKED - Symbol Filter
Signal: USDJPY BUY
Reason: Symbol not in whitelist
Allowed Symbols: EURUSD, GBPUSD, XAUUSD
Action: Signal skipped
```

**Time Filter Block:**

```
⚠️ SIGNAL BLOCKED - Time Filter
Signal: EURUSD BUY
Current Time: 22:45 (Broker Time)
Allowed Hours: 08:00 - 20:00
Allowed Days: Mon-Fri (Today: Friday)
Action: Signal skipped
```

**Content Filter Block:**

```
⚠️ SIGNAL BLOCKED - Blacklist
Signal Text: "RISKY NEWS Trade - EURUSD BUY"
Matched Keyword: "RISKY"
Blacklist: RISKY, NEWS, AGGRESSIVE
Action: Signal skipped
```

**Filter Pass:**

```
✅ SIGNAL PASSED ALL FILTERS
Symbol: GBPUSD ✅ (in whitelist)
Time: 10:30 Tuesday ✅ (within hours)
Content: "VIP Signal: GBPUSD BUY" ✅ (whitelist match)
Action: Processing signal for order placement
```

***

### 📊 Filter Impact Analysis

**Test:** 500 signals over 3 months

| Filter Config           | Signals Passed | Win Rate | Profit | Drawdown |
| ----------------------- | -------------- | -------- | ------ | -------- |
| No Filters              | 500 (100%)     | 52%      | +15%   | -12%     |
| Symbol Only (Majors)    | 350 (70%)      | 54%      | +18%   | -10%     |
| Symbol + Time           | 200 (40%)      | 58%      | +22%   | -8%      |
| Symbol + Time + Content | 120 (24%)      | 62%      | +25%   | -6%      |

**Conclusion:** Proper filtering improves win rate and reduces drawdown by focusing on optimal conditions.

***

### 🚀 Quick Start Guide

#### **Step 1: Understand Your Signal Provider**

* What symbols do they trade?
* When do they send signals?
* Do they use specific keywords?

#### **Step 2: Set Symbol Filter**

```
EnableListSymbol = true
ListSymbol = "[your broker's exact symbol names]"
```

Verify in Market Watch!

#### **Step 3: Set Time Filter (Optional)**

```
EnableTimeFilter = true
StartHour = [optimal start]
EndHour = [optimal end]
StartDay = 1
EndDay = 5
```

#### **Step 4: Set Content Filters (Optional)**

```
// If signal provider uses tags:
EnableWhitelist = true
Whitelist = "VIP,PREMIUM"

// If you want to avoid certain types:
EnableBlacklist = true
Blacklist = "RISKY,NEWS"
```

#### **Step 5: Monitor & Adjust**

* Check EA logs for blocked signals
* Adjust filters based on performance
* Balance selectivity vs signal frequency

***

### 📞 FAQ

**Q: No orders opening at all?** A: Check logs for filter blocks. Likely symbol names don't match or time filter too restrictive.

**Q: Can I use regex in whitelist/blacklist?** A: No, simple keyword matching only. Keywords are case-insensitive.

**Q: How to trade only one specific symbol?** A: `EnableListSymbol = true`, `ListSymbol = "EURUSD"` (single symbol).

**Q: Time filter not working?** A: Verify broker server time (check MT4 Market Watch time). Convert your local time.

**Q: Can I have different filters per symbol?** A: Not directly. Use separate EA instances or file config feature.

***

**Remember:** Filters are powerful tools to align signal execution with your strategy and schedule. Use them wisely! 🎯


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://copier-docs.redfox-capital.com/config/trading-filters-guide.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
