Learn how to run n8n workflows manually using the Execute Workflow button, webhooks, API, CLI, and scheduling for testing or on-demand execution.
Book a call with an Expert
Starting a new venture? Need to upgrade your web app? RapidDev builds application with your growth in mind.
To run n8n workflows manually, you can use the "Execute Workflow" button in the workflow editor, trigger them via webhooks, use the API endpoints, or schedule them for one-time execution. Manual execution allows you to test workflows during development or run on-demand processes without waiting for automatic triggers.
A Comprehensive Guide to Running n8n Workflows Manually
Step 1: Understanding Manual Workflow Execution in n8n
Before diving into the methods of running workflows manually, it's important to understand what manual execution means in n8n:
n8n offers several methods to run workflows manually, each suited for different scenarios and use cases.
Step 2: Running a Workflow Using the Execute Workflow Button
The simplest way to run a workflow manually is using the Execute Workflow button in the n8n editor:
This method instantly runs the entire workflow from start to finish and shows the execution results in real-time.
Step 3: Executing from a Specific Node
Sometimes you may want to run only a portion of your workflow:
This will execute the workflow starting from that specific node, which is useful for testing complex workflows in segments.
Step 4: Using Test Data for Manual Execution
When running workflows manually, you can provide test data:
For example, if you're testing an HTTP request, you might use:
{
"data": {
"name": "Test User",
"email": "[email protected]"
}
}
This allows you to simulate specific data scenarios without needing actual trigger data.
Step 5: Running Workflows via Webhook Triggers
If your workflow contains a Webhook node, you can manually trigger it by making an HTTP request:
For example, with curl:
curl -X POST -H "Content-Type: application/json" -d '{"data": "test"}' https://your-n8n-instance.com/webhook/path
This method is useful for integrating with external systems or for triggering workflows from scripts.
Step 6: Manual Execution via the n8n API
n8n provides a REST API that allows you to trigger workflows programmatically:
Here's how to execute a workflow using the API with curl:
curl -X POST \\
http://your-n8n-instance.com/api/v1/workflows/1/execute \\
-H 'X-N8N-API-KEY: your-api-key' \\
-H 'Content-Type: application/json' \\
-d '{
"workflowData": {
"startNodes": ["Start"],
"destinationNode": "End",
"executionMode": "manual"
}
}'
Replace:
1
with your workflow IDyour-n8n-instance.com
with your n8n hostyour-api-key
with your n8n API key
Step 7: Executing Workflows with n8n CLI
You can use the n8n command-line interface to run workflows:
For workflows saved in your n8n instance:
n8n execute --id=1
For workflows saved as JSON files:
n8n execute --file=/path/to/workflow.json
This method is particularly useful for server environments or scheduled tasks.
Step 8: Creating a Manual Trigger Node
The Manual Trigger node is specifically designed for workflows that need manual execution:
When you want to run the workflow:
The Manual trigger node can also be configured to accept input parameters, making it versatile for different execution scenarios.
Step 9: Scheduling One-Time Executions
For workflows that need to run once at a specific time:
Configuration example:
This method is technically an automated execution, but it's useful for planned one-time manual operations.
Step 10: Using the Execute Workflow Node
You can run workflows from within other workflows:
This is powerful for creating modular workflow systems where you manually trigger a master workflow that executes several sub-workflows.
Step 11: Passing Data to Manual Executions
When executing workflows manually, you might want to pass specific data:
Example of passing data via the API:
curl -X POST \\
http://your-n8n-instance.com/api/v1/workflows/1/execute \\
-H 'X-N8N-API-KEY: your-api-key' \\
-H 'Content-Type: application/json' \\
-d '{
"data": {
"customer": {
"id": 12345,
"name": "Example Customer"
}
}
}'
This allows you to provide context-specific information during manual execution.
Step 12: Monitoring Manual Executions
After manually triggering a workflow, you can monitor its execution:
This helps in debugging and understanding the workflow's behavior during manual runs.
Step 13: Setting Up Error Handling for Manual Executions
For more robust manual workflows, configure error handling:
This ensures you're notified if something goes wrong during manual execution, which is especially important for critical workflows.
Step 14: Using Environment Variables with Manual Executions
When running workflows manually in different environments:
This allows the same workflow to behave differently based on the environment, without changing the workflow itself.
Step 15: Best Practices for Manual Workflow Execution
To ensure smooth manual executions:
Following these best practices will help maintain workflow reliability and security, especially for critical business processes that require manual intervention.
When it comes to serving you, we sweat the little things. That’s why our work makes a big impact.