# Using organization\_name url within callback URL does not seem to work

**URL:** <https://community.auth0.com/t/using-organization-name-url-within-callback-url-does-not-seem-to-work/135311>\
**Category:** Get Help\
**Tags:** configuration, application\
**Created:** [May 30, 2024, 6:08pm UTC](https://community.auth0.com/t/using-organization-name-url-within-callback-url-does-not-seem-to-work/135311 "2024-05-30T18:08:51Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jthibeaux](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/jthibeaux/32/50641_2.png) [@jthibeaux](https://community.auth0.com/u/jthibeaux)\
**Post date:** [May 30, 2024, 6:08pm UTC](https://community.auth0.com/t/using-organization-name-url-within-callback-url-does-not-seem-to-work/135311/1 "2024-05-30T18:08:51Z")

</div>

We have a set of subdomains intended to use for different organizations (i.e. the organization name should match the subdomain), so it seemed to follow that we should be able to use the {organization\_name} component in the callback URL in order to indicate which organization should be gated to each subdomain. However, if we just include https://{organization\_name}.ourdomain.com/api/auth as the callback, we get an immediate error on attempting to login. We can only get this to work if we include each subdomain in the callback url list, and this allows a user in different domains to still log into every other subdomain regardless if they are a member of that organization.

Are we misunderstanding how this is intended to be used? What is the actual use case for an organization URL?

---

<div class="post-metadata">

**Author:** ![remus.ivan](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/remus.ivan/32/68771_2.png) [@remus.ivan](https://community.auth0.com/u/remus.ivan)\
**Post date:** [May 15, 2025, 7:05pm UTC](https://community.auth0.com/t/using-organization-name-url-within-callback-url-does-not-seem-to-work/135311/3 "2025-05-15T19:05:20Z")

</div>

Hi @jthibeaux,

Welcome to the Auth0 Community !

Your understanding is correct, you must specify the different subdomains in your callback URLs as mentioned in our documentation on the matter - [Subdomain URL Placeholders](https://auth0.com/docs/get-started/applications/wildcards-for-subdomains), but also stated by this knowledge article - [Dynamic Callback URLs with Wildcards](https://community.auth0.com/t/dynamic-callback-urls-with-wildcards/90619/1)

> - A placeholder **must not** be used in conjunction with a wildcard in the URL. `https://{organization_name}.*.exampleco.com` will not work.

However you can keep the {organization\_name} placeholder in order to have an exact match when it comes to the Callback URL list, but you can deny access to any user that is trying to authenticate to that specific organization from the server-side, after inspecting the token and comparing the org\_id claim to the id of the intended organization for the current subdomain.

I’m sorry for the late reply, but I hope this helps your use and others as well!  
Thanks,  
Remus

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [May 29, 2025, 7:05pm UTC](https://community.auth0.com/t/using-organization-name-url-within-callback-url-does-not-seem-to-work/135311/4 "2025-05-29T19:05:32Z")

</div>

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