Skip to main content

ONNX Runtime WebGPU Plugin Execution Provider

WebGPU Plugin Execution Provider for ONNX Runtime.

Prerequisites

This package provides the WebGPU plugin EP only. You must separately install an ONNX Runtime package (e.g. onnxruntime) of version 1.24.4 or later.

If the installed ONNX Runtime is incompatible, the plugin EP will report an error when its library is registered.

On Linux, a system Vulkan loader (libvulkan.so.1) must be installed and available at runtime.

Supported Platforms

Platform
Windows x64
Windows arm64
Linux x64 (manylinux)
Linux aarch64 (manylinux)
macOS arm64

Installation

pip install "onnxruntime>=1.24.4"
pip install onnxruntime-ep-webgpu

Usage

import numpy as np
import onnxruntime as ort
import onnxruntime_ep_webgpu as webgpu_ep

# Register the plugin EP library with ONNX Runtime
ort.register_execution_provider_library("webgpu", webgpu_ep.get_library_path())

# Discover WebGPU EP devices
# The WebGPU EP currently accepts one EP device and selects the physical GPU independently.
webgpu_ep_device = next((d for d in ort.get_ep_devices() if d.ep_name == webgpu_ep.get_ep_name()), None)
if webgpu_ep_device is None:
    raise RuntimeError("No WebGPU EP device found.")

# Create a session using the WebGPU EP
sess_options = ort.SessionOptions()
sess_options.add_provider_for_devices([webgpu_ep_device], {})
session = ort.InferenceSession("model.onnx", sess_options=sess_options)

# Run inference (replace shape/dtype/name to match your model)
input_data = np.zeros((1, 3, 224, 224), dtype=np.float32)
output = session.run(None, {"input": input_data})

Troubleshooting

  • No WebGPU EP device found — the plugin EP loaded but no compatible adapter was discovered. On Linux this usually means the Vulkan loader (libvulkan.so.1) is not installed; install it via your distribution's package manager. On Windows it may indicate a missing or outdated GPU driver.
  • ORT runtime version "..." is below the minimum required version "1.24.4" — the installed onnxruntime package is older than 1.24.4. Upgrade with pip install --upgrade "onnxruntime>=1.24.4".

Metadata

Release files for onnxruntime-ep-webgpu 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for onnxruntime-ep-webgpu 0.4.0
File
onnxruntime_ep_webgpu-0.4.0-py3-none-win_arm64.whl Python 3 none Windows ARM64 Details
onnxruntime_ep_webgpu-0.4.0-py3-none-win_amd64.whl Python 3 none Windows x86-64 Details
onnxruntime_ep_webgpu-0.4.0-py3-none-manylinux_2_28_x86_64.whl Python 3 none Linux glibc 2.28+ x86-64 Details
onnxruntime_ep_webgpu-0.4.0-py3-none-manylinux_2_28_aarch64.whl Python 3 none Linux glibc 2.28+ ARM64 Details
onnxruntime_ep_webgpu-0.4.0-py3-none-macosx_14_0_universal2.whl Python 3 none macOS 14.0+ universal2 (ARM64, x86-64) Details

Total release size: 45.5 MB

Release files / onnxruntime_ep_webgpu-0.4.0-py3-none-win_arm64.whl

Download URL onnxruntime_ep_webgpu-0.4.0-py3-none-win_arm64.whl
Size 14.2 MB
Tags Python 3 Windows ARM64
SHA-256 checksum
How to use checksums
a9586f6744370776059edd794c11bca2f563258a5bd2707864aefff31d3af39f
BLAKE2b-256 checksum
How to use checksums
cd35e1b1b12e596354d05af43cea09cd9fbd8a24b6df3853c527307b5cfb8d4b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via RestSharp/106.13.0.0

Release files / onnxruntime_ep_webgpu-0.4.0-py3-none-win_amd64.whl

Download URL onnxruntime_ep_webgpu-0.4.0-py3-none-win_amd64.whl
Size 13.1 MB
Tags Python 3 Windows x86-64
SHA-256 checksum
How to use checksums
7db646669d1a2390551da675115ea125e68cb3d4d2c3a2d6e463372bf8d6ea87
BLAKE2b-256 checksum
How to use checksums
d7a4c98a9e9433b3eeb576977b26c5c1cd0364f15ba9d198bb16101e7563ab06
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via RestSharp/106.13.0.0

Release files / onnxruntime_ep_webgpu-0.4.0-py3-none-manylinux_2_28_x86_64.whl

Download URL onnxruntime_ep_webgpu-0.4.0-py3-none-manylinux_2_28_x86_64.whl
Size 6.9 MB
Tags Linux glibc 2.28+ x86-64 Python 3
SHA-256 checksum
How to use checksums
5d8c961eda91a88961cad1fb7621f389f006b18497d6ea9ecf96f729f066cbfb
BLAKE2b-256 checksum
How to use checksums
c1962a18a45079250afcd825687aef2895de266d5abc1cff9f52d2dede7598f2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via RestSharp/106.13.0.0

Release files / onnxruntime_ep_webgpu-0.4.0-py3-none-manylinux_2_28_aarch64.whl

Download URL onnxruntime_ep_webgpu-0.4.0-py3-none-manylinux_2_28_aarch64.whl
Size 6.1 MB
Tags Linux glibc 2.28+ ARM64 Python 3
SHA-256 checksum
How to use checksums
17f660db53b1a509c63e721ac6784a2daa1c4e91a968523ee9986505ee5b0a55
BLAKE2b-256 checksum
How to use checksums
4eca00c70322c19913c81a6bb2239aca83781b97a818b55c2ec3d25cec72dc4c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via RestSharp/106.13.0.0

Release files / onnxruntime_ep_webgpu-0.4.0-py3-none-macosx_14_0_universal2.whl

Download URL onnxruntime_ep_webgpu-0.4.0-py3-none-macosx_14_0_universal2.whl
Size 5.2 MB
Tags Python 3 macOS 14.0+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
8d0a91d44b43d931c3068b9134aed9770f27803e353c2b58c93e1700bb68bcca
BLAKE2b-256 checksum
How to use checksums
c39f1e09865bbe4c9202ff1334545535be32dfdbeffc46e7d4c36c5de67ffafe
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via RestSharp/106.13.0.0

Release history Release notifications | RSS feed

This release

0.4.0 This release

5 release files

0.3.0

4 release files

0.2.1

4 release files

0.1.0

3 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page