Auth0 Home Blog Docs

jQuery Login not working in Zendesk App



I am integrating Auth0 in my zendesk application. When I try login using jQuery Login the redirect URL part is not working.

AUTH0_CALLBACK_URL = window.location.origin;

  var webAuth = new auth0.WebAuth({
    domain: AUTH0_DOMAIN,
    clientID: AUTH0_CLIENT_ID,
    redirectUri: AUTH0_CALLBACK_URL,
    audience: 'https://' + AUTH0_DOMAIN + '/userinfo',
    responseType: 'token id_token',
    scope: 'openid'

on clicking login button it displays the error message “http://localhost:4567/index.html?” is not in the list of allowed callback URLs.

even though I have added http://localhost:4567/… in Allowed Callback URLs in “Auth0 Management API (Test Application)” settings. This work fine in web application.

How to make allowed callback URLs Dynamic, or is there other way to integrate Auth0 in Zendesk application without redirect url .

Thanks in advance.


For others who may encounter a similar issue, the application is running inside an iframe, since it was running embedded in Zendesk, and so when the Google authentication was trying to load it could not as it cannot be loaded inside an iframe. This results in a blank page. A possible alternative would be to trigger the authentication flow through the means of a popup; this community post may contain useful information on this (Auth0.js Popup Autoclose).

If anyone came here for trying to achieve dynamic redirect after authentication you will find a good explanation on that here:


This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.