Cannot connect Azure DevOps organization to Azure Active Directory

I have created an Azure DevOps organization. I have created it with my outlook account. I want to connect it to Azure Active Directory (AAD), Default Directory, on my Azure portal. I am using the free account on Azure portal which allows me to have one subscription. The AAD directory is shown below:

enter image description here

I want to connect my Azure DevOps organization to Azure Active Directory. I am using the same user in Azure portal and Azure DevOps. I have basically created both by the same account. I am following the instruction at this link to connect Azure DevOps organization to Azure AD. I emphasize that in my case both are created by the same email. However, in Azure DevOps Organization settings, by clicking on “connect directory” under “Azure Active Directory”, I get an error that: “User is a guest in the target AAD tenant Default Directory. The current organization policy does not allow guest users to access the organization. Change the policy setting to allow external guest access and try again.”

This is what I see at organization settings in DevOps:

Azure DevOps Organization Settings

This is the error when I try to connect it to AAD:

enter image description here

When I check my user in Azure Active Directory I can see it has global admin role, and is a member, not guest! It is after all the user by which I have created this account and all the resources: (It is the user on the second row:)

User in AAD

As mentioned earlier, this user has global administrator role:

enter image description here

I also tried changing my policies at AAD side to be able to connect my DevOps project to AAD, but again it fails. This is how the policies are:

external collaboration policy

I basically don’t know what else I should do to connect DevOps to AAD. Any help is appreciated.

Read more here: Source link