cloudflare/workers-rs

Write Cloudflare Workers in 100% Rust via WebAssembly

View on GitHub ↗Jump to charts ↓Open shareable report

Summary Information

Updated 43 minutes ago
Added to GitGenius on February 28th, 2026
Created on August 10th, 2021
Open Issues & Pull Requests: 184 (+0)
Number of forks: 422
Total Stargazers: 3,623 (+0)
Total Subscribers: 48 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 31.3 hours
Mean response time: 124.0 days
90th percentile: 555.1 days
Tracked items: 149

How this project is maintained

Around half of the issues opened in the past year never receive a reply. 99% of open issues come from outside the core team, so the backlog reflects real-world use rather than internal planning. Only 8% of issues opened in the past year have been closed. Three people close 65% of everything that gets resolved.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 104
New in 7 days: 0
Closed in 7 days: 0
Avg open age: 704 days
Stale 30+ days: 102
Stale 90+ days: 93

Recent activity

Opened in 7 days: 0
Closed in 7 days: 0
Comments in 7 days: 0
Events in 7 days: 0

Top labels

  • bug (11)
  • enhancement (6)
  • good first issue (6)
  • ecosystem-compat (3)
  • ffi (1)
  • hacktoberfest (1)
  • wasm-bindgen (1)

Most active issues this week

No issue events were indexed in the last 7 days.

Detailed Description

The workers-rs repository provides ergonomic Rust bindings for developing Cloudflare Workers entirely in Rust, compiled to WebAssembly. This project enables developers to write serverless functions on Cloudflare's edge computing platform using Rust instead of JavaScript, leveraging the wasm32-unknown-unknown compilation target to produce efficient WebAssembly modules.

The repository is classified across multiple domains including Cloudflare, Rust, Serverless, Edge computing, WebAssembly, Platform, Development, API, and Runtime. It serves as a bridge between the Rust ecosystem and Cloudflare's Workers platform, allowing developers to use standard Rust crates and modules as long as they compile to the WebAssembly target. The project uses wrangler, Cloudflare's command-line tool, for running and publishing workers locally and to production.

The repository maintains connections with major projects including Microsoft's VSCode, the Rust language repository, and Microsoft's TypeScript project through overlapping contributor networks.

The crate provides several key features for building workers. An HTTP feature flag introduced in version 0.0.21 replaces custom types with standard types from the http crate, enabling direct use of frameworks like axum and hyper. The Router abstraction allows parameterized routes with access to route parameters, shared data, environment bindings, and request context within handler functions.

Bindings to Cloudflare services are accessible through environment parameters provided to entrypoints and route handlers. The repository supports Durable Objects, which require implementing the DurableObject trait with the durable_object attribute macro. Durable Objects can leverage SQLite for persistent relational database storage through the state.storage().sql() interface. Key-Value storage, Secrets, Variables, and Version metadata bindings are all supported through the environment interface.

The project includes experimental support for Workers RPC, allowing inter-worker communication. RPC servers export methods using wasm-bindgen, while RPC clients require manual binding generation. The repository provides an experimental code generator for describing RPC interfaces using WIT (WebAssembly Interface Type), a lightweight format designed for the WebAssembly Component model, with support currently limited to primitive types.

CPU limit detection is available through the worker::signals API, enabling graceful backoff when workers approach platform-imposed CPU limits. The panic recovery feature with the --panic-unwind flag allows panics to be caught and converted to JavaScript exceptions rather than terminating the WebAssembly instance, enabling workers to continue serving requests after panic events. This feature uses the nightly Rust toolchain and rebuilds std with panic unwinding support, automatically recovering from critical errors by reinitializing the WebAssembly instance on subsequent requests.

Getting started with workers-rs involves using cargo generate to scaffold from templates, with optional configuration for panic unwinding and abort recovery. The project is published on crates.io as the worker crate and maintains comprehensive documentation on docs.rs.