---
title: "n8n with EU-hosted models · OpenAI credential setup"
description: "Point n8n's OpenAI credential at inference.eu and run AI Agent and Chat Model workflows on open-weight models processed in EU data centres."
canonical: "https://inference.eu/integrations/n8n/"
language: "en"
---

Automation · n8n

# Use n8n with open-source models hosted in the EU

n8n is a workflow automation platform with AI agent nodes. Its OpenAI credential has a Base URL field, so the OpenAI Chat Model, AI Agent and other OpenAI-based nodes can run on open-weight models at inference.eu, processed in European data centres.

[Contact sales](https://inference.eu/contact/)[Setup](#setup)

1.  01API format: OpenAI
2.  02EU data centres
3.  03Covered by one DPA

## Set it up in a few minutes

1.  1

    Create an API key in your inference.eu account.

2.  2

    In n8n, go to Credentials, create a new OpenAI credential, paste your key as API Key and set Base URL to the inference.eu base URL.

3.  3

    Add an AI Agent or Basic LLM Chain node and attach an OpenAI Chat Model sub-node using the new credential.

4.  4

    Choose the model from the list or set it By ID, for example `gpt-oss-120b`, and leave Use Responses API switched off.

5.  5

    Run the workflow once with a test message to confirm the model answers.

bash

```
# Creates an OpenAI credential that points at inference.eu.
# In the UI instead: Credentials > Create > OpenAI, then fill in API Key and Base URL.
cat > inference-eu-credential.json <<EOF
[{
  "name": "inference.eu",
  "type": "openAiApi",
  "data": { "apiKey": "$INFERENCE_EU_API_KEY", "url": "https://api.inference.eu/v1" }
}]
EOF
n8n import:credentials --input=inference-eu-credential.json
rm inference-eu-credential.json
```

## What n8n is

n8n is a workflow automation platform that you can self-host or use as a cloud service. Workflows connect triggers, hundreds of app integrations and code steps, and its AI nodes, built on LangChain, add agents with tools and memory, chains, document loaders and vector stores. Teams use it to automate support triage, document processing, reporting and internal assistants.

Language models are attached to AI nodes as Chat Model sub-nodes. The OpenAI credential accepts a custom Base URL, so the OpenAI Chat Model sub-node, and other nodes that use the same credential, can send their requests to inference.eu instead.

## How the configuration works

Create an OpenAI credential with your inference.eu key as API Key and the inference.eu base URL, ending in `/v1`, as Base URL. When n8n tests the credential, it calls `/models` at that address. Every node using the credential then sends requests to inference.eu.

In the OpenAI Chat Model sub-node, select the credential and pick a model from the list, or switch to By ID and type it. The node also has a Base URL option of its own, which overrides the credential for that node only. Keep Use Responses API off so the node uses Chat Completions. Self-hosted administrators can create the credential from the command line with `n8n import:credentials`.

## Which models to choose

AI Agent nodes call tools in a loop, so they need a model with dependable tool calling: `kimi-k3` and `glm-5.3` are strong defaults for agents that look up records, call APIs or update systems. For classification, extraction and short text generation inside a workflow, `gpt-oss-120b` keeps each execution quick.

Use `glm-5.3` or `kimi-k3` when a step summarises long documents or emails. For workflows that generate or review code, `qwen3-coder-480b-a35b-instruct` is a good fit. Each Chat Model sub-node has its own model setting, so one workflow can use a fast model for routing and a stronger one for the main agent.

## Troubleshooting

If the credential test fails with 401, the key is wrong or has extra spaces. A 404 usually means Base URL is missing `/v1` or has an extra path. If the model list is empty, set the model By ID instead.

n8n warns that models behind a custom Base URL may not support every feature. If the AI Agent returns tool calls as text or loops, choose a model with stronger tool calling. If you see errors about built-in tools or conversation IDs, Use Responses API is switched on; turn it off. Remember that sub-nodes resolve expressions only for the first input item.

## Keeping data in the EU

With the credential pointed at inference.eu, the prompts, records and tool results your workflows send to the model are processed in EU data centres and never used for training. We sign a data processing agreement under Article 28 GDPR, publish our subprocessor list and bill in euros.

n8n stores workflow executions, including inputs and outputs, in its own database. Self-host n8n in the EU for full control over that data, or check the hosting region of your n8n plan. Self-hosted instances can turn off usage diagnostics with `N8N_DIAGNOSTICS_ENABLED=false`. Other nodes in a workflow send data to their own services.

## n8n

Category

Automation

Maker

n8n

API format

OpenAI

Processing

EU data centres

Website

[n8n.io](https://n8n.io/)

Documentation

[github.com](https://github.com/n8n-io/n8n/blob/master/packages/nodes-base/credentials/OpenAiApi.credentials.ts)

## n8n: common questions

The questions buyers, developers and legal teams ask us most. Something missing? Ask us directly.

Yes. The OpenAI credential has a Base URL field that overrides the default OpenAI address. Set it to the inference.eu base URL and every node using the credential, including the OpenAI Chat Model sub-node, sends its requests there.

Attach an OpenAI Chat Model sub-node to the AI Agent, select the OpenAI credential that points at inference.eu, and choose a model such as Kimi K3 or GLM-5.3. Add tools and memory as usual; the agent then runs on inference.eu.

Kimi K3 and GLM-5.3 are strong defaults for AI Agent nodes that call tools. gpt-oss-120b suits quick classification and extraction steps, and Qwen3 Coder 480B is a good choice for workflows that work with code.

No. Leave it off so the node uses Chat Completions, which every inference.eu model supports. The Responses API option is designed for OpenAI's built-in tools and conversation features, which are specific to OpenAI's platform.

The node loads models from the credential's Base URL. If the list stays empty, check the credential test succeeds, or switch the model field to By ID and type the inference.eu model id directly, for example \`gpt-oss-120b\`.

A 401 means the API key is wrong or contains extra spaces. A 404 means Base URL is missing \`/v1\` or includes a path such as \`/chat/completions\`. A timeout points to outbound network or proxy settings on the n8n server.

Yes. The OpenAI Chat Model node has a Base URL option that overrides the credential for that node. For clarity, most teams create a dedicated OpenAI credential named after inference.eu and reuse it across workflows.

Self-hosted n8n sends anonymous usage diagnostics unless you set \`N8N\_DIAGNOSTICS\_ENABLED=false\`. Execution data stays in your database. On n8n's cloud service, executions are stored on n8n's own infrastructure under its terms, so check its hosting region.

Yes, on self-hosted instances. Write a JSON file with \`type\` set to \`openAiApi\` and \`data\` containing \`apiKey\` and \`url\`, then run \`n8n import:credentials --input=<file>\`. Delete the file afterwards, because it contains the key in plain text.

Only if you configure them to. Embedding sub-nodes and vector stores have their own credentials and settings. Choose EU-hosted or self-hosted options for them so that documents processed in your workflows stay in Europe.

[Ask a question](https://inference.eu/contact/)

## Related

[All integrations](https://inference.eu/integrations/)

-   [DifyAdd inference.eu to Dify with the OpenAI-API-compatible plugin and build chatbots, agents and workflows on open-weight models processed in the EU.Automation](https://inference.eu/integrations/dify/)
-   [FlowisePoint Flowise's ChatOpenAI Custom node at inference.eu with a custom Base Path and build chatflows and agents on open-weight models processed in the EU.Automation](https://inference.eu/integrations/flowise/)
-   [LiteLLMAdd inference.eu to the LiteLLM proxy or Python SDK with the openai/ prefix and route your team's requests to open-weight models processed in the EU.Gateways](https://inference.eu/integrations/litellm/)

## Move your AI workloads to EU infrastructure

Tell us which models you use and roughly how much traffic you have. We reply within one working day with pricing and next steps.

-   Reply within one working day
-   Pricing for your volume
-   DPA ready to sign
