Skip to main content
Here’s a pattern you’ll run into constantly in automation: you need to do the same thing to a bunch of items. Maybe you’re enriching 500 contacts. Or categorizing 200 support tickets. Or scoring 100 leads. Your first instinct might be to build one giant flow that handles everything at once. But that gets complicated fast—and when something breaks, good luck figuring out where. There’s a better way: Subflows.

The philosophy: Perfect one, then scale many

Think of Subflows as your “build once, use everywhere” tool. You create a flow that does one thing perfectly—like enriching a single contact. You test it, refine it, make sure it works exactly right. Then, instead of rebuilding that logic every time you need it, you just drop that Subflow into other flows like it’s any other node. The magic? When you connect a list to a Subflow, it automatically runs for every item in that list. You built it for one, but it scales to thousands.

When Subflows make sense

You’re processing lists of similar items Enriching contacts, analyzing reviews, generating reports—anything where you’re applying the same logic repeatedly. Your flow is getting messy If you’re scrolling through 50+ nodes to find something, that’s a sign you need to break things into Subflows. You’re repeating yourself Building similar flows across projects? Turn the common parts into reusable Subflows. You want to test incrementally It’s way easier to debug “enrichment isn’t working” when that’s isolated in its own Subflow, rather than buried in a massive flow.
Think in modules, not monolithsJust like you wouldn’t write all your code in one massive function, you don’t want one massive flow. Subflows let you break complex automations into logical, reusable pieces.

How Subflows actually work

At their core, Subflows are just regular flows with two special things: 1. Inputs – What the Subflow needs to do its job Instead of starting with a trigger or data source, you use Input nodes to say “this Subflow expects an email address and a company name.” 2. Outputs – What the Subflow returns You use Output nodes to specify exactly what information comes back out. “After all this processing, return the person’s title, their industry, and a company description.” Between those inputs and outputs? Whatever logic you need. Enrichment nodes, AI, scrapers, calculations—anything. Once you’ve built a Subflow, it shows up in your node library just like native nodes. You can drop it into any other flow, connect your data, and it works.

The power of loop mode + Subflows

Remember loop mode from earlier lessons? When you pass a list into a node that expects a single value, it automatically loops—running once for each item. That’s exactly what happens with Subflows. Build a Subflow that enriches one contact. Connect a list of 500 contacts to it. Gumloop runs your Subflow 500 times automatically—once per contact. You built the logic once. Loop mode handles the scale.
Subflows vs regular flows: what’s the difference?Technically? Nothing. A Subflow is just a flow that you’ve designed to be reusable. The difference is in how you build it: with clear inputs and outputs so it can plug into other flows easily. Think of it like the difference between a script you wrote for yourself vs a function you wrote for others to use.

Real-world Subflow patterns

Here are some common ways you’ll use Subflows: List processing You’ve got a spreadsheet of data. Build a Subflow that processes one row perfectly, then apply it to all rows. Multi-step enrichment Contact enrichment often involves 3-4 different APIs and some AI. Bundle that complexity into one clean Subflow. Report generation Build a Subflow that generates a report for one customer. Use it across different flows and triggers. Data transformation Converting, cleaning, or restructuring data? Build the transformation once as a Subflow, reuse it everywhere.
Start with test dataWhen building a Subflow, use Input nodes with real test data. This lets you run and debug your logic before connecting it to your actual data source. Get it working perfectly on one example, then scale with confidence.

Building modular, scalable automations

Subflows are how you graduate from “I built a flow” to “I built a system.” Instead of one-off automations that only work in specific contexts, you create building blocks you can mix and match. Your enrichment Subflow works in your sales flow, your onboarding flow, and your reporting flow. That’s the difference between automating tasks and automating at scale. You now know:
  • How to identify workflows worth automating
  • How to build flows with nodes and connections
  • How to run flows automatically with triggers, interfaces, and schedules
  • When to use native vs MCP nodes
  • How to organize and scale with Subflows
Next up: learn how to combine the power of Agents and Flows by using Agents as nodes in your workflows. 🚀