금. 8μ›” 15th, 2025

D: Ever felt like your automations need smart decision-making? The n8n If Node is your secret weapon! πŸ› οΈ This powerful node lets you create branching workflows based on conditions, making your automations smarter and more dynamic.

In this ultimate guide, we’ll break down the If Node with 10 real-world examplesβ€”from simple checks to advanced logic. Let’s dive in!


πŸ” What is the n8n If Node?

The If Node evaluates conditions and routes data based on whether they’re true or false. Think of it as a traffic controller 🚦 for your workflowβ€”sending data down different paths depending on rules you set.

Key Features:

βœ… Supports multiple conditions (AND/OR logic)
βœ… Works with data from previous nodes (e.g., JSON, numbers, text)
βœ… Customizable comparisons (=, >, <, contains, etc.)


πŸ› οΈ 10 Practical If Node Examples

1️⃣ Basic Email Filtering

Scenario: Sort emails into “Important” and “Others” based on subject keywords.

Condition:  
πŸ“Œ IF `{{$node["Gmail"].json["subject"] contains "URGENT"}}` → Branch A (Send Slack alert)  
πŸ“Œ ELSE → Branch B (Archive email)  

2️⃣ E-Commerce Discount Checker

Scenario: Give discounts to orders over $100.

Condition:  
πŸ’° IF `{{$node["Shopify"].json["orderTotal"] > 100}}` → Apply 10% discount  
πŸ’³ ELSE → Proceed to checkout  

3️⃣ Social Media Auto-Reply

Scenario: Reply differently to tweets with hashtags.

Condition:  
🐦 IF `{{$node["Twitter"].json["text"] contains "#support"}}` → Send help guide  
❀️ ELSE IF `contains "#feedback"` → Send thank-you message  

4️⃣ Weather-Based Alert System

Scenario: Notify if rain is forecasted.

Condition:  
β˜” IF `{{$node["OpenWeather"].json["weather"] == "Rain"}}` → SMS alert "Bring an umbrella!"  
β˜€οΈ ELSE → Do nothing  

5️⃣ CRM Lead Scoring

Scenario: Tag high-value leads (score > 75).

Condition:  
πŸ† IF `{{$node["HubSpot"].json["leadScore"] > 75}}` → Tag as "Hot Lead"  
πŸ“Œ ELSE → Tag as "Follow Up"  

6️⃣ Form Response Router

Scenario: Route survey responses to different teams.

Condition:  
πŸ“Š IF `{{$node["Typeform"].json["feedbackRating"] < 3}}` → Send to "Complaints" team  
πŸ‘ ELSE → Send to "Success" team  

7️⃣ Inventory Restock Alert

Scenario: Trigger a purchase order if stock is low.

Condition:  
⚠️ IF `{{$node["Airtable"].json["quantity"] < 10}}` → Email supplier  
πŸ”„ ELSE → Update inventory log  

8️⃣ Time-Based Greeting

Scenario: Send “Good Morning/Evening” messages.

Condition:  
πŸŒ… IF `{{$node["DateTime"].json["hours"] < 12}}` → Send "Good Morning"  
πŸŒ‡ ELSE → Send "Good Evening"  

9️⃣ Failed Payment Retry

Scenario: Retry failed transactions under $50.

Condition:  
πŸ”΄ IF `{{$node["Stripe"].json["status"] == "failed" AND amount < 50}}` → Retry payment  
🟒 ELSE → Log error  

πŸ”Ÿ Multi-Language Support

Scenario: Route customer queries by language.

Condition:  
πŸ‡¬πŸ‡§ IF `{{$node["Zendesk"].json["language"] == "en"}}` → English support  
πŸ‡ͺπŸ‡Έ ELSE IF `== "es"` → Spanish support  

πŸ’‘ Pro Tips for If Node Success

πŸ”Ή Use Javascript for complex logic (e.g., date comparisons, regex).
πŸ”Ή Test conditions separately with the “Execute Node” feature.
πŸ”Ή Combine with Switch Node for multi-route workflows.


🎯 Final Thoughts

The n8n If Node turns rigid workflows into intelligent, adaptive systems. Whether filtering data, routing tasks, or triggering alerts, mastering conditions unlocks next-level automation.

πŸš€ Try these examples in your workflows today! Need help? Drop a comment below. πŸ‘‡

#n8n #Automation #Workflow #NoCode #IfNode

λ‹΅κΈ€ 남기기

이메일 μ£Όμ†ŒλŠ” κ³΅κ°œλ˜μ§€ μ•ŠμŠ΅λ‹ˆλ‹€. ν•„μˆ˜ ν•„λ“œλŠ” *둜 ν‘œμ‹œλ©λ‹ˆλ‹€