redirect does not happen and it takes me to auth on twitter , i do that and it goes in loop of asking me to auth on twiter. any help will be greatly appreciated. i have a free version and testing things before i upgrade to paid version.
Describe the problem/error/question
What is the error message (if any)?
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:
@msshaikh1030 the screenshot shows X is asking u to log in first — u arent logged into twitter.com in that browser, so when n8n redirects to X for OAuth, X drops u at login instead of the authorize page, and after u log in it kicks the auth flow into a loop. open a new tab, log into X.com directly there, then come back to n8n and hit Connect again. also worth checking — any privacy extensions or third-party cookie blocking on, that’ll break the redirect handoff too.
i tired that you just mentioned, opened a new tab, and logged in to my Twitter account and that works fine. Can back to work flow and tried to login, it keeps coming back to the same login page. Deleted the node and recreated but no luck.
ok so loop continuing past the login step means X itself is rejecting the authorize request — usually a config mismatch in ur X app. in the X dev portal under User Authentication Settings, check: App type should be “Web App, Automated App or Bot” (not Native), App permissions need to be at least “Read and write”, and the Callback URI has to EXACTLY match the OAuth Redirect URL n8n shows u (copy-paste it from n8n’s credential modal, dont retype). more setup detail at X (formerly Twitter) credentials | n8n Docs.
A corrupted cache is the most common culprit for login loops.
Open your browser and clear your cookies and cache for the past 7 days.
Hello,
Yes, i have the setup correct, see below, i cleared my cache, changed the browsers. I tried another oauth2 with wordpress and ,i get the popup but cant authorise .
i cleared that for last month.(last 4weeks) , no change.
Welcome @msshaikh1030 to our community! I’m Jay and I am a n8n verified creator.
The loop issue is almost always a callback URL mismatch in your X Developer App settings - clearing cookies won’t fix it. Go to the X Developer Portal, open your app, and under “User authentication settings” make sure https://oauth.n8n.cloud/oauth2/callback is listed as an allowed callback URI. Also check that your app has “OAuth 2.0” enabled and the appropriate permissions (Read and Write at minimum). Once saved, re-create the credential in n8n and try connecting again.
You say we should use this link: https://***/oauth2/callback
But N8N says this link:https://***/rest/oauth2-credential/callback
Both doesnt work, tried both in the call URI under app info and still stuck in loop
@msshaikh1030 Were you able to find a solution for this error? running into the same problem
No, still looking for the answer.
thanks
not sure ,is it n8n or X.com or something else. can get much help either.
thanks
@msshaikh1030
Please share the JSON to understand the case.
I recommend updating to the new updated version released in June, 2.23.2
So my developer helped me and its something with X, it doesn’t send you to the success link, he inspected the code, found the link manually and put it into the browser and Voola it worked
can you share that method ?
One thing that gets a lot of people stuck here: in the X.com Developer Portal, after you create an app and get your Client ID/Secret, there is a separate section called “User authentication settings” that needs to be explicitly enabled. Go to your app → Settings → User authentication settings → turn on OAuth 2.0, set the app type to “Web App”, and add the callback URL https://oauth.n8n.cloud/oauth2/callback there. If that section is not enabled, the OAuth flow will either redirect to a login loop or show the “you have to be logged in” page even when you are. Also make sure the app has at least “Read” permissions enabled in the same section.