Describe the problem/error/question
I’m running n8n on Windows Server behind IIS reverse proxy using pm2.
Flow:
Client → IIS → n8n (pm2)
When I first started and logged in, I got:
ValidationError: The 'X-Forwarded-For' header is set but the Express 'trust proxy' setting is false (default).
This could indicate a misconfiguration which would prevent express-rate-limit from accurately identifying users.
See https://express-rate-limit.github.io/ERR_ERL_UNEXPECTED_X_FORWARDED_FOR/ for more information.
I found forum post #51208 recommending N8N_PROXY_HOPS=1.
That solved the first error. ![]()
What is the error message (if any)?
The new error after restart
After restarting pm2, I got another error: ERR_ERL_INVALID_IP_ADDRESS
ValidationError: An invalid 'request.ip' (49.49.33.138:48115) was detected.
Consider passing a custom 'keyGenerator' function to the rate limiter.
See https://express-rate-limit.github.io/ERR_ERL_INVALID_IP_ADDRESS/ for more information.
Please share your workflow
(Select the nodes on your canvas and use the keyboard shortcuts CMD+C/CTRL+C and CMD+V/CTRL+V to copy and paste the workflow.)
Share the output returned by the last node
Information on your n8n setup
- n8n version:
- Database (default: SQLite):
- n8n EXECUTIONS_PROCESS setting (default: own, main):
- Running n8n via (Docker, npm, n8n cloud, desktop app):
- Operating system: