dbt Cloud makes it simple to orchestrate and manage your analytics workflows. In this guide, weโll walk through configuring Microsoft Fabric Warehouse as a connection in dbt Cloud using a Service Principal for secure authentication.
I will also include all prerequisites, step-by-step instructions, and screenshots to make the setup seamless.
โ Prerequisites
Before starting, make sure you have:
- A Microsoft Fabric account with admin permissions.
- Access to the Azure portal with permissions to register applications and create secrets.
- A dbt Cloud account (Team or Enterprise plan) with Orchestration enabled.
๐ Step 1: Register an Application & Add Service Principal
- Log in to the Azure Portal.
- In the navigation menu, select Microsoft Entra ID (formerly Azure Active Directory).
- Go to App registrations โ + New registration.

4. Enter a Name for your application.

- Under Supported account types, select: Accounts in this organizational directory only
- Click Register.
๐ Make a note of:
- In theย Supported account typesย section, selectย Accounts in this organisational directory onlyย and clickย Register.
- Make a note of theย Application (client) IDย andย Directory (tenant) ID These values will be needed in dbt Cloud.

๐ Step 2: Create a Client Secret
- Open the application you registered in Step 1.
- From the left menu, select Certificates & secrets โ + New client secret.
- Provide a Description and select an Expiry period.
- Click Add.


๐ Copy and save the client secret value. You will not be able to view it again later.

๐ข Step 3: Enable Service Principal in Microsoft Fabric
- Log in to your Microsoft Fabric account.
- Click the Settings (โ๏ธ) icon in the top right.
- Under Governance and Insights โ Admin portal.
- Navigate to Tenant settings.
- Under Developer settings, set: Service principals can use Fabric APIs โ ON

Under OneLake settings, set: Users can access data stored in OneLake with apps external to Fabric โ ON

๐ Step 4: Create a Workspace & Add Service Principal
- From the Fabric navigation menu, go to Workspaces โ + New workspace.
- Enter a Name and click Apply.
- Select your new workspace โ Manage Access.
- Click + Add people or groups.
- Add the Service Principal created in Step 1.
- Assign the role Contributor.

๐ Step 5: Create a Lakehouse or Warehouse
- In Fabric, click Create โ Lakehouse or Warehouse (depending on your use case).
- Provide a unique name and click Create
- Retrieve the SQL endpoint for Lakehouse/Warehouse we use in dbt setup

โ๏ธ Step 6: Configure dbt Cloud Environment
Now letโs connect Fabric to dbt Cloud.
In dbt Cloud, go to Settings โ Connections โ Connection settings
- Type:
fabric
- Settings:
- Server: SQL endpoint from step 5
- port : 1433
- Database: <fabric>

- In dbt Cloud, go to Orchestration โ Environments โ + New Environment.
- Environment name:
fabric-dbt
- Environment type:
Deployment
- Deployment type:
STG
orPROD
as needed - dbt version:
Latest
- Environment name:

2. Scroll down to Connection settings:
- Connection: Fabric
- Authentication: Service Principal
- Tenant ID โ (from Step 1)
- Client ID โ (from Step 1)
- Client Secret โ (from Step 2)
- Schema โ
dbo
(or your schema of choice)

- Click Test Connection.
- If successful, youโll see: โ COMPLETE โ Your test completed successfully, youโre good to go!
- Click Save.
Your dbt Cloud environment is now fully connected to Microsoft Fabric Warehouse using a Service Principal.
๐ Wrap Up
Youโve successfully:
- Registered a Service Principal in Azure
- Enabled Fabric API & OneLake access
- Created a Workspace and Warehouse
- Configured dbt Cloud to connect securely using Service Principal
Now you can start building and orchestrating your dbt models on Microsoft Fabric Warehouse!