To use OpenRouter in WordPress, you add one OpenRouter API key in your plugin’s Settings, then pick any of the hundreds of models it offers on a per-node basis inside your workflow builder. AI Workflow Automation, a free WordPress plugin, treats an OpenRouter key exactly like a native provider key: once it is saved, every AI Prompt node in the builder can route to a different model without touching PHP or a second plugin.
AI Workflow Automation is a free WordPress plugin with a visual drag-and-drop builder that runs AI workflows, agents, and chatbots inside your own site, using your own API keys, with no external subscription required. OpenRouter fits into that setup exactly like an OpenAI key: once the key is added in Settings, it becomes a selectable provider on the Model tab of any AI Prompt node you build.
Several free tools already connect a single OpenRouter key to a single WordPress feature, usually one chat box or one generator. This guide covers a broader case: one OpenRouter key powering an entire visual workflow, with a different model on every node. If you only need a single OpenAI key for one job, our guide on connecting WordPress to OpenAI without code covers that narrower case.
What is OpenRouter, and why use it with a WordPress plugin?
OpenRouter is a hosted service that gives a single account and a single API key access to hundreds of AI models from providers including OpenAI, Anthropic, Google, Meta, and Mistral. Instead of creating a separate account and key with each model provider, a developer signs up once with OpenRouter, and every supported model becomes reachable through one endpoint.
OpenRouter’s own Quickstart guide puts it plainly: “OpenRouter gives you access to hundreds of AI models through a single API endpoint.” For a WordPress site, that removes a specific kind of lock-in: a workflow built around one model does not need rebuilding when a cheaper or better model comes along, because the change happens in one dropdown on one node, not in code.
Inside the AI Model node, which the palette labels AI Prompt, OpenRouter is one of three provider choices on the Model tab: WordPress AI, which uses your site’s own configured provider on WordPress 7.0 and up; OpenAI (Direct); and Via OpenRouter. Picking Via OpenRouter is what opens up the wider catalog.
How do you add an OpenRouter API key to AI Workflow Automation?
Adding OpenRouter takes one key and one settings screen, the same screen every other AI provider in the plugin uses. You generate the key on openrouter.ai, paste it into the plugin once, and from then on every AI Prompt node in every workflow on the site can use it.
Open wp-admin, then AI Workflows, then Settings. Under the AI provider keys section, enable OpenRouter and paste the key. The provider row links straight to the page on openrouter.ai where you generate it, so you do not need to leave the plugin to find it. You can also set OpenRouter as your default provider, so new AI nodes start pointed at it.
The key is encrypted at rest in your WordPress database, the same storage every other provider key uses, and it is used only for direct calls from your server to OpenRouter. It is never sent to our platform.
How do you route an AI Prompt node through OpenRouter, step by step?
Every AI Prompt node asks which provider to use, and OpenRouter is one of the three choices on that node’s Model tab. Building a small workflow with two OpenRouter models, one cheap and one strong, is the fastest way to see the routing actually work once the key is saved.
- Create a workflow in AI Workflows and add a trigger, for example a Manual trigger or a form trigger, so there is an input to work with.
- Drag an AI Prompt node onto the canvas. The node palette calls it AI Prompt; it is documented as the AI Model node.
- Open the Model tab and choose Via OpenRouter from the provider list, then use the search box to find a model. The catalog loads live from OpenRouter, so it reflects whatever models are currently available.
- Write the prompt, referencing the trigger’s data with a variable tag such as
[Input from trigger-1], and save the node. - Add a second AI Prompt node for a different job, for example classifying the same input by urgency, and set its Model tab to a smaller, faster OpenRouter model than the first node uses.
- Connect both nodes to the trigger, add an output such as Send Email or Create Post/Product to act on whichever result matters, then click Save and Run.
- Watch the live execution panel to confirm both nodes ran against the models you picked, then change either node’s Model tab independently the next time you want to test a different one.

Inside the Model tab, any model ID that contains a slash, such as an Anthropic or Google entry, routes through OpenRouter. A bare model ID with no slash routes straight to OpenAI instead, which is how the same tab can send one node to OpenRouter and another to OpenAI without changing anything else about the workflow. See Data Flow and Variable Handling for the full variable tag syntax used in the prompt itself.
Which model should you pick for which task?
Not every step in a workflow needs the same amount of model. A short classification task and a full article draft have different requirements, and picking a smaller model for the easy step is the main lever you have over both cost and speed once a key is in place.
| Task in the workflow | What it needs | Model tier to pick |
|---|---|---|
| Tagging, routing, or sentiment on short text | Low latency, low cost, simple instructions | A small, fast model |
| Drafting a support reply or short email | Balanced quality and cost | A mid-size general-purpose model |
| Writing a full article or long-form draft | Strong reasoning, style, and coherence over length | A frontier or flagship model |
| Extracting structured fields from messy text | Reliable instruction-following | A model known for following schemas closely |
| Reasoning over an image or screenshot | Multimodal input | A vision-capable model |
None of this is fixed. OpenRouter’s catalog changes as providers release new models, and the Model tab reloads that catalog live rather than shipping a hardcoded list, so a model that counts as small today may not next year. Treat the table as a way of thinking about the job, not a fixed set of names to memorize.
What happens if a model you picked goes down or gets rate limited?
A workflow that hardcodes one model to one provider has a single point of failure: if that provider has an outage or throttles your account, every node using it stops working until you notice and fix it by hand. OpenRouter’s own infrastructure reduces part of that risk for models you reach through Via OpenRouter.
Two layers sit upstream of the plugin. First, when more than one company hosts the same model, OpenRouter’s Provider Routing documentation explains: “You can include the sort field in the provider preferences.” Leave that unset and OpenRouter load-balances across the providers hosting a model on its own; set it, and it tries providers in a fixed order instead.
Second, OpenRouter separately documents an Auto Router, a selectable catalog entry that picks a model per request rather than a provider per model, describing its behavior as choosing “the top surviving models (in market spend-share order)” as “the primary pick plus fallbacks.” Provider load-balancing happens on OpenRouter’s side for a normal model pick; model-level fallbacks only apply if you choose the Auto Router entry itself. Neither is configured inside AI Workflow Automation, so if a specific model matters to a workflow, check the run history after an outage rather than assuming it recovered.
How do you see what your OpenRouter usage is costing you?
Local workflows that use your own OpenRouter key are billed by OpenRouter directly, inside your OpenRouter account, not through AI Workflow Automation. The plugin still gives you visibility into that spend from inside WordPress, through its own dashboard, so you do not have to leave wp-admin to see whether a workflow got expensive.
Open Settings, then Cost Management, to see daily cost, API call counts, and token usage over the last 7, 30, or 90 days, or a custom range. Because every model routed through OpenRouter carries its own price per token, switching a node from a frontier model to a smaller one is usually visible in that chart within a day.
OpenRouter’s own FAQ states it “pass[es] through the pricing of the underlying providers without any markup,” so a request through OpenRouter costs the same per token as calling that provider directly. This is Local mode with your own key, so none of it touches AI Workflow Automation’s own credits; those only come into play if you separately choose Cloud, where an optional cloud mode runs workflows on our hosted engine for credits.
Frequently asked questions
Is OpenRouter free to use?
OpenRouter itself is free to sign up for and charges no subscription. You add credits to an OpenRouter balance, and each request deducts its cost from that balance. Inside AI Workflow Automation, using your own OpenRouter key is also free on the plugin’s side: it is Local mode with your own key, so nothing is deducted from the plugin’s separate credit system.
Can I use OpenRouter and a direct OpenAI key in the same workflow?
Yes. The AI Prompt node’s Model tab sets the provider per node, not per workflow, so one node can call OpenAI directly while another node in the same workflow routes through OpenRouter. This is useful when you already have a direct OpenAI key for one job and want OpenRouter’s wider catalog for everything else, without replacing the key you already use.
Which AI models can I access through OpenRouter in WordPress?
Whatever OpenRouter currently lists, since AI Workflow Automation loads its model catalog live rather than shipping a fixed list. That typically includes models from Anthropic, Google, Meta, Mistral, and other providers alongside OpenAI’s own models. Use the search box on the Model tab to filter the list, and the reload button if you expect a newly released model to appear.
Does routing through OpenRouter cost more than going directly to a provider?
No, not for the model call itself. OpenRouter passes through the underlying provider’s own pricing without a markup, so a request routed through OpenRouter costs the same per token as calling that provider directly. The separate cost sits on OpenRouter’s own credit purchases, where topping up your balance carries a small payment processing fee.
The fastest way to see this for yourself is to add one OpenRouter key and point two nodes at two different models in the same workflow. Install AI Workflow Automation free from the WordPress plugin directory, and if you are building your first workflow, the quick start guide walks through the builder before you add a second model to the mix.