Multi-Tenant Structure without subdomains

default discord avatar
last month

Hi all,

I’d like to create a multi-tenant cms


the tenants having different subdomains or domains.

So all tenants log into, and then they see their own entries. Is that even possible with the official tutorial?

I cloned the tutorial-repo and changed a bit. For example deleted the "domains" from the seed file. And without further configuration my approach does not seem to work, as all tenant users are "unauthorized" to access the default url

How could I change it so all users can log in at the same url?

Oh and somewhat relevant to this, is it possible to add Globals for tenants? So the user of can set their global, and can set their information in the same global.

Update in case someone has the same issue:

The Login wasn’t possible anymore, as the utility


checked only one tenant, as it riginally filtered all tenants from the domain. You need to change the tenantWithUser check to something like this:

const tenantWithUser = user?.tenants?.find(({ tenant: userTenant }) =>{ id }) => id === userTenant?.id)
    Open the post
    Continue the discussion in Discord
    Like what we're doing?
    Star us on GitHub!


    Connect with the Payload Community on Discord



    Can't find what you're looking for?

    Get help straight from the Payload team with an Enterprise License.