Can I use OAuth2 or JWT to connect Salesforce to n8n?
n8n supports both OAuth2 and JWT authentication for Salesforce. Pick whichever method fits your setup when creating your Salesforce credential.
Which one should I use?
OAuth2 is the default and easiest to set up, since n8n Cloud provides a pre-configured callback flow.
JWT works well for service-account style connections that don't depend on a user login session — for example, background integrations, API-only users, or orgs with strict session policies.
Both methods work with Salesforce's newer External Client Apps and the legacy Connected Apps. Salesforce is phasing out Connected Apps, so use External Client Apps for any new setup.
Where do I choose this in n8n?
When creating a Salesforce credential, use the Authentication dropdown to select OAuth2 or JWT, then fill in the fields shown for that method.
Setup steps
Full setup steps for both methods, including the Salesforce-side app configuration, are in the Salesforce credentials documentation.
Still stuck?
If your credential test fails or you get a Salesforce authentication error, contact support at help@n8n.io with the exact error message.