3 Better Ways To Find Azure Tenant ID

Prajwal Desai
Posted by Prajwal Desai
Find Azure Tenant ID

There are multiple ways to find Azure Tenant ID and in this post I will cover 3 easy methods to find the tenant ID.

When you create an Azure account and add a Azure subscription, the subscriptions have a trust relationship with Azure AD. Azure AD is trusted to authenticate users, services, and devices for the subscription. Each subscription has a tenant ID associated with it, and there are a few ways you can find the tenant ID for your subscription.

You can find the Azure Tenant ID using 3 methods.

  • Find Azure tenant ID with PowerShell
  • Find Azure Tenant ID with CLI
  • Find Tenant ID through Azure Portal

Finding Tenant ID through Azure portal is the easiest way out of all three. However the choice varies for every user because some people love using PowerShell to do their daily tasks. While others feel easier to find the tenant ID using Azure portal. Let’s look at each of these methods in detail.

Find Tenant ID through Azure portal

You can find Tenant ID through Azure portal using below steps.

  • Sign in to the Azure portal.
  • Under Azure Services, select Azure Active Directory. You can also find it using the search box.
  • Click the Overview tab and look for Tenant Information. The Azure tenant ID is displayed.
  • You can also copy the Tenant ID using Copy to Clipboard option.
Find Tenant ID through the Azure portal
Find Tenant ID through the Azure portal

The other alternate way to find tenant ID through Azure portal is to click Properties in the left pane. That should also reveal your Tenant ID.

find tenant ID through Azure portal
find tenant ID through Azure portal

Find Azure Tenant ID with PowerShell

Using the below two commands you can find Azure Tenant ID with PowerShell.

  • Connect-AzAccount
  • Get-AzTenant

However you cannot directly run these commands because you must first install the Azure PowerShell module.

Launch the PowerShell as administrator and run the command.

Install-Module -Name Az
Install Azure PowerShell module
Install Azure PowerShell module

First run the command Connect-AzAccount. You may need to sign in to Azure with your credentials. When you successfully sign-in, the command shows the following details.

  • Account Name – Email address with which you have signed-in
  • Subscription Name – The subscription name assigned to your account.
  • Tenant ID – Azure Tenant ID
  • Environment – Azure Cloud

You can also find Azure Tenant ID with PowerShell command Get-AzTenant. Running this command shows the following details.

  • Tenant ID
  • Name
  • Category
  • Domains
Find Azure Tenant ID with PowerShell
Find Azure Tenant ID with PowerShell

Find Azure Tenant ID with CLI

You can find Azure Tenant ID with CLI however you must first download and install Azure CLI. If you want to use a command-line interface to find the tenant ID, you can do so with Azure CLI or Microsoft 365 CLI. This post doesn’t cover the Azure CLI installation.

On the Azure CLI download page, you get two options.

  • Azure CLI current version
  • Azure CLI beta version

I recommend downloading the Azure CLI current version MSI installer. The beta version does not guarantee product level quality so it should not be used in your production environment.

Download the Azure CLI current version and install it on your server. Let’s find Azure tenant ID with CLI.

Launch the PowerShell or Command Prompt as administrator. Run the command Az login. If the CLI can open your default browser, it will do so and load an Azure sign-in page. If you haven’t configured a default browser, you may do that when you run the Az login command.

Run the command Az account tenant list. When you run this command it prompts you to install an extension account. Install the extension and in the output you should find the Azure Tenant ID.

Find Azure Tenant ID with CLI
Find Azure Tenant ID with CLI

Share This Article
Prajwal Desai
Posted by Prajwal Desai
Follow:
Prajwal Desai is a Microsoft MVP in Intune and SCCM. He writes articles on SCCM, Intune, Windows 365, Windows Server, Windows 11, WordPress and other topics, with the goal of providing people with useful information.
Leave a comment