Get All Personal Sites In SharePoint Online

We can fetch all personal sites that are provisioned in our tenant using the below scripts. 
  1. #Parameter required  
  2. Param(  
  3.  [string]$Username,  
  4.  [string]$Password,  
  5.  [string]$SPAdminUrl   
  6. )  
  7.   
  8. $SecurePassword = ConvertTo-SecureString -String $Password -AsPlainText -Force  
  9. $Credential = New-Object -TypeName "System.Management.Automation.PSCredential" -ArgumentList $Username, $SecurePassword  
  10. Connect-SPOService -Url $SPAdminUrl -Credential $Credential  
  11. Write-Host "#Connected to SP Tenant"  
  12. $OD4BSites =  Get-SPOSite -IncludePersonalSite $true -Template "SPSPERS#10"  
  13. Write-Host "There are total "$OD4BSites.Length  
  14. Foreach($OD4BSite in $OD4BSites){      
  15.     Write-Host $OD4BSite.Url  
  16. }  
Save the above as a PowerShell script and execute it. Please find the output image below.