Platform Requirements

What your operating system needs to compile and bundle Tauri v2 desktop applications, with specific setup instructions for Windows, macOS, and Linux.

Building a Tauri application means compiling a Rust backend that links against the operating system’s webview and native libraries, then bundling the result into an installer your users can run. Each platform has its own set of tools and system libraries that must be present for this to succeed. If anything is missing, the build will fail with errors that are often cryptic – a missing header file, a linker complaint, or a silent inability to produce a .msi or .deb. The System Dependencies Overview chapter is the install walkthrough; this page is what the build itself requires.

The requirements on this page are the ones that apply when you are running tauri build or tauri dev on a development machine. Some of them also affect whether a built app can launch on an end-user’s machine, but those runtime constraints are covered in Packaging Applications and Distribution.


Windows

Two categories of tools are needed: a C++ compiler and related build utilities for the Rust code, and the WebView2 SDK so Tauri can compile the windowing layer. The Rust toolchain itself (installed via rustup) defaults to the MSVC ABI on Windows – the GNU/MinGW target is not supported.

Visual Studio Build Tools

The Rust compiler depends on the Microsoft C++ linker and Windows SDK headers when targeting *-pc-windows-msvc. Without them, even a basic cargo build will fail.

Install Visual Studio Build Tools 2022 (the free, standalone package – no full Visual Studio IDE required). During installation, select the workload “Desktop development with C++”. This pulls in the MSVC toolchain, the Windows 10/11 SDK, and the CMake tools some native dependencies may require.

You can install silently with winget:

winget install Microsoft.VisualStudio.2022.BuildTools `
  --override "--wait --quiet --add Microsoft.VisualStudio.Workload.VCTools"

After installation, restart any open terminals so the new PATH entries are picked up.

WebView2 Runtime

Tauri compiles against the WebView2 SDK that ships with the Evergreen WebView2 Runtime. On Windows 11 it is already included. On Windows 10, if you’ve kept the system updated, it is likely present as well.

To verify or install it manually, download the Evergreen Standalone Installer from Microsoft’s official page and run it. The tiny “Bootstrapper” is enough; the full offline installer is unnecessary for development.

One-Time Setup:

Once the WebView2 Runtime is installed, Rust’s webview2-com crate will find the headers automatically. No additional configuration is required.

Rust Target

The default Rust toolchain on Windows sets itself to x86_64-pc-windows-msvc. Confirm with:

rustup show

If you need a different architecture (32-bit or ARM64), add the corresponding target:

rustup target add i686-pc-windows-msvc
rustup target add aarch64-pc-windows-msvc

WiX and NSIS (Bundling)

The Tauri CLI ships with NSIS and WiX v3 binaries embedded, so you do not need to install them separately to produce -setup.exe and .msi installers. If you want to customize WiX templates or use a different version, you would install the WiX Toolset manually, but that is a packaging detail, not a build requirement.

MSI Builds Are Windows-Only:

WiX can only run on Windows. You cannot produce .msi installers from a macOS or Linux build machine. Use NSIS (-setup.exe) if you must cross-compile from another OS.


Linux

Tauri v2 requires webkit2gtk-4.1 – the newer WebKit API for GTK 3 that uses libsoup3. This single dependency determines which Linux distributions can be used as build hosts.

Supported Distributions

Only distributions that ship with glibc ≥ 2.35 and offer the webkit2gtk-4.1 package are viable. Practically, this means:

  • Ubuntu 22.04 or later
  • Fedora 37 or later
  • Debian 12 (Bookworm) or later
  • Arch Linux (rolling)

Older enterprise releases like RHEL 9 / CentOS Stream 9, Ubuntu 20.04, and Debian 11 provide only webkit2gtk-4.0 (the libsoup2 variant), which Tauri v2 cannot link against.

Unsupported Distro – Build Will Fail:

If you try to build on Ubuntu 20.04, CentOS 9, or a similar older release, the Rust crate soup3 will fail because gio 2.70+ is unavailable. The error message will mention a missing gio or glib version. There is no workaround short of upgrading the distribution or using a Flatpak-based builder.

Required System Packages

Use the package manager that matches your distribution. The commands below install the webview library, GTK development headers, SSL, and common utilities needed by native crates.

sudo apt update
sudo apt install -y \
  libwebkit2gtk-4.1-dev \
  build-essential \
  curl \
  wget \
  file \
  libxdo-dev \
  libssl-dev \
  libayatana-appindicator3-dev \
  librsvg2-dev

After installing, verify that the correct WebKit version is available:

pkg-config --modversion webkit2gtk-4.1

It should print a version like 2.40.0 or higher.

Bundler Dependencies (Optional)

By default, tauri build tries to produce a .deb, an .rpm, and an AppImage. The first two require some extra system tools:

  • .deb packages: dpkg-dev (or the dpkg package that includes dpkg-deb)
  • .rpm packages: rpm-build

If you are only interested in the AppImage, you can skip those – the AppImage bundler downloads its own runtime. To restrict the output formats, set bundle.targets in tauri.conf.json to a list like ["appimage"].

AppImage Runtime Caveats:

The generated AppImage bundles the application’s own libraries but still relies on a compatible glibc on the target user’s system. An AppImage built on Ubuntu 24.04 may not run on Ubuntu 20.04 because of GLIBC_2.38 symbols. If you need broad compatibility, build on the oldest supported distribution (Ubuntu 22.04) or distribute via Flatpak.


macOS

Building on macOS requires Apple’s command-line tools and, if you plan to ship a universal binary that runs on both Intel and Apple Silicon, both Rust targets.

Xcode Command Line Tools

Even if you never open Xcode, the compiler, linker, and SDK headers come from the command-line tools package. Install it with:

xcode-select --install

Accept any license prompts by running sudo xcodebuild -license after installation.

Rust Targets

If you are on an Apple Silicon Mac and only build for your own architecture, the default toolchain (aarch64-apple-darwin) is enough. For a release that supports Intel Macs as well, add the Intel target:

rustup target add x86_64-apple-darwin

Building a universal binary then requires two separate compilations (one per target) and combining the results with lipo. The tauri build command does not do this automatically – you would run it twice with --target flags, as described in the packaging section. At this stage, ensuring the targets are installed is what matters.

Minimum Deployment Target

The bundler’s default minimumSystemVersion is 10.13 (High Sierra). Modern Rust and Xcode setups can target versions as far back as that, but if you need a higher floor, adjust it in the configuration later. No extra tooling is required to satisfy the default.


Platform-Specific Configuration Files

Tauri merges optional platform-specific configuration files with the main tauri.conf.json. You can create any of these next to the main config:

  • tauri.windows.conf.json
  • tauri.macos.conf.json
  • tauri.linux.conf.json

They use the same schema but only need to contain the values that differ for that platform. For example, to force static linking of the VCRuntime on Windows (the default is already true, so this is illustrative):

src-tauri/tauri.windows.conf.json
{
  "build": {
    "windows": {
      "staticVCRuntime": true
    }
  }
}

Or to raise the minimum macOS version for the bundle without touching the main config:

src-tauri/tauri.macos.conf.json
{
  "bundle": {
    "macOS": {
      "minimumSystemVersion": "11.0"
    }
  }
}

This separation keeps the main configuration clean and avoids #[cfg]-style clutter in the Rust code for simple build-time options.


Verifying Your Setup

Tauri ships a diagnostic command that inspects your environment and reports what is missing:

cargo tauri info

A fully prepared Windows machine will show checkmarks for the MSVC toolchain, the WebView2 runtime, and the Rust target. On Linux, the critical line is webkit2gtk-4.1: installed. On macOS, the command verifies that Xcode command-line tools are reachable.

All Clear:

If tauri info prints checkmarks for every entry under “Environment”, the platform requirements are satisfied. Any red ✘ indicates a missing component that will cause a build or runtime failure.


Cross-Compilation Quick Reference

Building an app for a different operating system than the one you are running on is possible but comes with extra setup and caveats.

FromToWhat You Need
Linux / macOSWindowscargo-xwin, nsis, llvm + lld linker, x86_64-pc-windows-msvc target
WindowsLinuxNot supported directly – use a Linux VM or CI (GitHub Actions)
Intel MacApple SiliconThe aarch64-apple-darwin target (Xcode handles the rest)

Cross-compiling for Windows from Linux is the most documented path. An example for an Ubuntu host:

rustup target add x86_64-pc-windows-msvc
cargo install --locked cargo-xwin
sudo apt install nsis lld llvm

Then invoke Tauri with the extra runner and target:

pnpm tauri build --runner cargo-xwin --target x86_64-pc-windows-msvc

This produces an NSIS installer. WiX-based MSI builds remain Windows-only regardless of the host.

Cross-Builds Are Best-Effort:

Cross-compilation is tested less thoroughly than native builds. If you hit linking errors or missing symbols, a CI runner on the target OS (e.g., GitHub Actions with windows-latest) is the more reliable fallback.


Summary

The platform requirements for building a Tauri v2 application boil down to a short, non-negotiable checklist per operating system. On Windows, the MSVC C++ toolchain and the WebView2 runtime are the gatekeepers. On Linux, the webkit2gtk-4.1 package dictates which distributions can even attempt a build, with Ubuntu 22.04 as the practical baseline. On macOS, the Xcode command-line tools and optional Intel target cover everything.

Before moving on to build optimization or packaging, run cargo tauri info and make sure every line under “Environment” lights up green. That one check prevents nearly all common build failures rooted in missing system dependencies.