Windows Code Signing
Secure your Tauri v2 application for Windows distribution by code signing with OV certificates or Azure Key Vault to avoid SmartScreen blocks and build user trust
Users who download your Tauri app from the internet will almost certainly encounter a full-screen warning from Windows SmartScreen if the binary is not signed. "Windows protected your PC" with a blocked run button is the default experience for any unsigned executable. Code signing replaces that experience with a publisher name and a smooth install flow — and in many enterprise environments, unsigned software is simply rejected by policy.
This guide covers everything you need to sign your Tauri v2 Windows executables: what certificates are available, how to configure signing with an OV certificate you already own, how to use Azure Key Vault for cloud‑based signing, and how to automate everything in CI. Pair this with Windows packaging.
Why Code Signing Matters on Windows
Windows ships with SmartScreen, a reputation-based filter that checks every downloaded executable. If a file has no valid digital signature, SmartScreen blocks it with a strong warning. If it is signed but the publisher has little download history, SmartScreen shows a milder "unrecognized app" prompt — still a friction point. A well-signed application that has accumulated reputation over many downloads eventually runs without any prompt at all.
Code signing proves two things: the software came from you (authenticity) and it hasn’t been tampered with since you signed it (integrity). The signature is checked against a certificate issued by a trusted Certificate Authority, and if valid, Windows displays your organization’s name in the User Account Control and SmartScreen dialogs.
For apps distributed outside the Microsoft Store, signing is not technically mandatory — but distributing unsigned software is a sure way to lose users before they even try your app.
Types of Signing Certificates
You can sign Windows executables with several kinds of certificates. Tauri supports all of them either directly or through a custom sign command.
OV (Organization Validated) Certificates
The standard choice for most independent developers and small teams. A Certificate Authority validates your legal organization identity before issuing the certificate. Once signed, your app’s publisher name appears in Windows prompts. Reputation builds over time as more users download and run your software.
Reputation Takes Time:
Even with a valid OV certificate, a brand-new signing identity will trigger SmartScreen warnings initially. The warnings fade as your file hash accumulates clean download history. There is no way to skip this phase with an OV certificate alone.
EV (Extended Validation) Certificates
EV certificates require a more rigorous identity check and the private key must be stored on a hardware security module (HSM). Historically, EV certificates bypassed SmartScreen instantly, but Microsoft changed this behavior in 2024. EV‑signed files now build reputation the same way OV certificates do. EV certificates are still required for signing kernel-mode drivers, but for a typical Tauri desktop app they offer no SmartScreen advantage over OV.
Azure Artifact Signing (formerly Trusted Signing)
Microsoft’s own cloud code signing service. You validate your identity once with Microsoft, then sign directly from your build pipeline without managing physical tokens. It costs roughly $9.99 per month and is the most straightforward path for automated signing in CI/CD. It provides the same OV-level reputation model. Availability is currently limited to specific regions (organizations in the US, Canada, EU, UK; individuals in US and Canada only).
Tauri Support:
Tauri v2 supports OV certificate signing out of the box through the Windows configuration fields. Azure Key Vault (the broader Azure service) is supported through the relic sign tool. Azure Artifact Signing can also be used by pointing Tauri to a custom sign command that wraps the Invoke-TrustedSigning PowerShell module, but this guide focuses on the two built‑in approaches: OV certificates and Azure Key Vault with relic.
Signing Your Tauri App
The method you choose depends on where your signing key lives. Pick the tab that matches your setup.
Signing with an OV Certificate
This path assumes you have already purchased a code signing certificate from a Certificate Authority and have the certificate file (.cer or .crt) and the private key file (.key). The goal is to produce a .pfx file, install it in your Windows certificate store, and tell Tauri which certificate to use.
Step 1: Convert your certificate to PFX format
If your CA provided a .pfx file directly, skip this step. Otherwise, use OpenSSL to bundle the certificate and private key.
openssl pkcs12 -export -in cert.cer -inkey private-key.key -out certificate.pfx
You will be prompted to set an export password. Do not lose this password — you will need it for the import step and for CI/CD secrets.
Password is not recoverable:
If you forget the export password, you cannot import the .pfx file. There is no reset mechanism. Store the password in a password manager immediately.
Step 2: Import the PFX into your certificate store
Open PowerShell and run:
$WINDOWS_PFX_PASSWORD = 'YOUR_EXPORT_PASSWORD'
Import-PfxCertificate -FilePath certificate.pfx -CertStoreLocation Cert:\CurrentUser\My -Password (ConvertTo-SecureString -String $WINDOWS_PFX_PASSWORD -Force -AsPlainText)
The certificate is now installed under the current user’s personal store.
Step 3: Find your certificate thumbprint
The thumbprint uniquely identifies the certificate. Do not rely on openssl pkcs12 -info — it sometimes shows a different local key ID, not the real thumbprint.
Instead, open certmgr.msc from the Start menu. Navigate to Personal > Certificates, double‑click your certificate, and go to the Details tab. Scroll down to Thumbprint. Copy the hex string (e.g., A1B1A2B2A3B3A4B4A5B5A6B6A7B7A8B8A9B9A0B0). Remove any spaces.
Wrong thumbprint = sign tool failure:
Using the value from openssl pkcs12 -info is a known source of SignTool Error: Invalid SHA1 hash format. Always get the thumbprint from the certificate manager.
Step 4: Configure tauri.conf.json
Open src-tauri/tauri.conf.json and locate the bundle > windows section. Add these fields:
{
"bundle": {
"windows": {
"certificateThumbprint": "A1B1A2B2A3B3A4B4A5B5A6B6A7B7A8B8A9B9A0B0",
"digestAlgorithm": "sha256",
"timestampUrl": "http://timestamp.digicert.com"
}
}
}
certificateThumbprint— the thumbprint you copied (no spaces).digestAlgorithm— hashing algorithm;sha256is standard.timestampUrl— a publicly available RFC 3161 timestamp server. Your CA likely provides one;http://timestamp.digicert.comworks universally.
Don't forget the publisher field:
Some configurations fail to sign if the publisher field is missing. Make sure your tauri.conf.json includes a bundle.publisher string — it can be your company name or the CN from your certificate. Tauri uses it as the manufacturer in the installer.
Step 5: Build and sign
Run the build command as usual:
npm run tauri build
In the output you should see lines similar to:
info: signing app
info: running signtool "C:\Program Files (x86)\Windows Kits\10\bin\10.0.19041.0\x64\signtool.exe"
info: "Done Adding Additional Store\r\nSuccessfully signed: APPLICATION FILE PATH HERE"
Signing succeeded:
If you see Successfully signed in the console, your .exe and installer are now digitally signed. You can verify the signature by right‑clicking the file, selecting Properties, and opening the Digital Signatures tab.
Automated Signing with GitHub Actions
Once you have signing working locally, you can automate it in CI. The following workflow snippet imports an OV certificate into the Windows runner and then builds with the Tauri action.
name: publish
on:
push:
branches:
- release
jobs:
publish-tauri:
strategy:
fail-fast: false
matrix:
platform: [windows-latest]
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v4
- name: setup node
uses: actions/setup-node@v4
with:
node-version: 20
- name: install Rust stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
- name: import windows certificate
if: matrix.platform == 'windows-latest'
env:
WINDOWS_CERTIFICATE: ${{ secrets.WINDOWS_CERTIFICATE }}
WINDOWS_CERTIFICATE_PASSWORD: ${{ secrets.WINDOWS_CERTIFICATE_PASSWORD }}
run: |
New-Item -ItemType directory -Path certificate
Set-Content -Path certificate/tempCert.txt -Value $env:WINDOWS_CERTIFICATE
certutil -decode certificate/tempCert.txt certificate/certificate.pfx
Remove-Item -path certificate -include tempCert.txt
Import-PfxCertificate -FilePath certificate/certificate.pfx -CertStoreLocation Cert:\CurrentUser\My -Password (ConvertTo-SecureString -String $env:WINDOWS_CERTIFICATE_PASSWORD -Force -AsPlainText)
- name: install app dependencies and build it
run: npm ci && npm run build
- uses: tauri-apps/tauri-action@v0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tagName: app-v__VERSION__
releaseName: 'App v__VERSION__'
releaseBody: 'See the assets to download this version and install.'
releaseDraft: true
prerelease: false
The two GitHub secrets you need:
| Secret | Value |
|---|---|
WINDOWS_CERTIFICATE | Base64-encoded .pfx file. Create it with certutil -encode certificate.pfx base64cert.txt and copy the content. |
WINDOWS_CERTIFICATE_PASSWORD | The export password you set when creating the .pfx. |
For Azure Key Vault, replace the certificate import step with environment variable exports for AZURE_TENANT_ID, AZURE_CLIENT_ID, and AZURE_CLIENT_SECRET (stored as GitHub secrets) and ensure relic is installed via cargo install relic before the Tauri action runs.
Verifying the Signature
After building, you can confirm the signature is present. In File Explorer, right‑click the .exe or installer, select Properties, and open the Digital Signatures tab. You should see your publisher name and a timestamp. Click Details → View Certificate to inspect the full chain.
For command‑line verification, use signtool:
signtool verify /pa /v path/to/your-app.exe
A successful verification ends with Successfully verified: path\to\your-app.exe.
Common Mistakes and Troubleshooting
Invalid SHA1 hash format:
This error from signtool almost always means the certificateThumbprint is wrong. Re‑open certmgr.msc, copy the thumbprint again, and make sure there are no spaces or hidden characters.
Signing fails with no clear error:
Check that bundle.publisher is set in tauri.conf.json. A missing publisher can cause silent signing failures. Also, confirm the timestamp server URL is reachable — some corporate networks block external timestamp servers.
SmartScreen still appears after signing:
This is expected for a new signing identity. Reputation is tied to the certificate and builds over time as users download and run your software. Signing every release consistently with the same certificate and timestamping helps reputation accumulate faster. Switching certificates or CAs resets the reputation clock.
Self‑signed certificates for local testing:
You can create a self‑signed certificate for development, but it will trigger a severe SmartScreen block on any machine that hasn’t manually installed the certificate as a trusted root. Use it only for internal testing — never for public distribution.
Summary
Windows code signing moves your Tauri application from a blocked unknown binary to a trusted installer. The quickest path for individual developers is an OV certificate combined with the simple certificateThumbprint configuration. For teams that want to keep the private key in the cloud and integrate seamlessly with CI, Azure Key Vault with relic is the recommended approach. Both methods integrate cleanly with Tauri’s build pipeline and the tauri-action GitHub Action.