Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. Rust
  3. phper

phper

NOASSERTIONRustphper-doc-v0.15.8

A framework for writing PHP extensions in pure, safe Rust, enabling high-performance native modules.

Visit WebsiteGitHubGitHub
354 stars21 forks0 contributors

What is phper?

PHPER is a framework that allows developers to write PHP extensions using the Rust programming language instead of C. It provides a safe, ergonomic interface to PHP's internal APIs, enabling the creation of high-performance native modules with Rust's memory safety guarantees. This approach reduces common vulnerabilities associated with traditional C extensions while maintaining compatibility with a wide range of PHP versions.

Target Audience

PHP developers and system engineers who need to create high-performance native extensions, particularly those looking to leverage Rust's safety and performance for PHP module development.

Value Proposition

Developers choose PHPER because it modernizes PHP extension development by replacing error-prone C code with safe Rust, offering better performance, memory safety, and a more developer-friendly API while maintaining broad PHP version and platform compatibility.

Overview

The framework that allows us to write PHP extensions using pure and safe Rust whenever possible.

Use Cases

Best For

  • Creating high-performance PHP extensions for custom functionality
  • Porting existing Rust libraries to be usable within PHP applications
  • Developing native tracing or monitoring agents for PHP (like SkyWalking)
  • Building language bindings between PHP and Rust codebases
  • Implementing computationally intensive operations as PHP native modules
  • Writing secure PHP extensions with memory safety guarantees

Not Ideal For

  • Teams developing exclusively on Windows, as PHPER lacks official support for Windows environments.
  • Projects with simple performance needs that can be met with pure PHP or existing extensions, where building a native extension is overkill.
  • Developers without Rust experience, who would face a steep learning curve to write extensions.
  • Rapid prototyping scenarios where using existing PHP libraries is faster than developing a custom extension.

Pros & Cons

Pros

Memory Safety Guarantees

Leverages Rust's ownership model to prevent common vulnerabilities like buffer overflows, making extensions more secure than traditional C-based ones, as emphasized in the philosophy.

Broad PHP Compatibility

Supports PHP versions from 7.0 to 8.5, including both NTS and ZTS modes, and works with CLI and FPM SAPIs, ensuring wide applicability across many environments.

Ergonomic Developer Experience

Provides a safe, ergonomic API that abstracts PHP's internal structures, simplifying extension development compared to raw C interfaces, as noted in the key features.

Production-Ready Validation

Used in real-world projects like Apache SkyWalking PHP Agent, demonstrating its stability and suitability for production, as shown in the projects list.

Cons

No Windows Support

Explicitly unsupported on Windows, limiting its use for developers or deployments in Windows-centric environments, as indicated in the tested support table.

Complex Setup Requirements

Requires Rust 1.85+, libclang 9.0+, and PHP 7.0+, adding dependency management overhead and setup complexity compared to pure PHP development.

Niche Ecosystem and Community

As a Rust-based framework for PHP extensions, it has a smaller community and fewer pre-built resources than traditional C extension tools, which might slow down development.

Frequently Asked Questions

Quick Stats

Stars354
Forks21
Contributors0
Open Issues0
Last commit1 day ago
CreatedSince 2019

Tags

#developer-tools#high-performance#php-extensions#native-modules#memory-safety#ffi#php7#php8#cross-platform#php#binding#extension#rust

Built With

l
libclang
R
Rust

Links & Resources

Website

Included in

Rust56.6k
Auto-fetched 1 day ago

Related Projects

RustPythonRustPython

A Python Interpreter written in Rust

Stars22,412
Forks1,502
Last commit1 day ago
PyO3PyO3

Rust bindings for the Python interpreter

Stars16,258
Forks1,039
Last commit1 day ago
wasm-bindgenwasm-bindgen

Facilitating high-level interactions between Wasm modules and JavaScript

Stars9,198
Forks1,257
Last commit1 day ago
NeonNeon

Rust bindings for writing safe and fast native Node.js modules.

Stars8,423
Forks287
Last commit20 days ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub