Forum Discussion
Key pair auth to Snowflake
- 6 months ago
Hi,
Yes, Power BI Service does support Snowflake Key Pair authentication, but it must be configured correctly in the Service (under Data source credentials / Manage connections and gateways). If it works programmatically but not in Power BI, it’s usually due to one of the following:
The private key format is not what Power BI expects (typically PKCS#8 PEM format).
The private key is encrypted and the passphrase is not entered correctly.
The RSA public key registered in Snowflake does not match the private key being used.
The account URL / user / role / warehouse differs from what was tested programmatically.
If a gateway is involved, the credentials must be configured on the gateway datasource in the Service (not just in Desktop).
Regarding your second question:
At this time, setting Snowflake Key Pair credentials via Power BI REST API is not fully supported for automation scenarios. While there are REST APIs for updating gateway datasource credentials, Key Pair authentication for Snowflake generally still requires manual configuration in the Power BI Service UI.If you can share the exact error message and whether you’re using a gateway or a cloud connection, it would help narrow down the issue further.
Hi nganesh , Thank you for reaching out to the Microsoft Community Forum.
We find the answer shared by mohit_sakhare is appropriate. Can you please confirm if the solution worked for you. It will help others with similar issues find the answer easily.
Thank you mohit_sakhare for your valuable response.