What Arbitrum Stylus actually does

Arbitrum Stylus is a WASM-based execution layer that runs alongside the EVM. It does not replace Ethereum Virtual Machine compatibility; instead, it adds a second lane for smart contracts written in Rust, C, and C++. These languages compile to WebAssembly (WASM), which Arbitrum nodes execute with near-instant finality.

This architecture allows developers to use high-performance languages for compute-heavy tasks while keeping the EVM for standard token logic. The result is a hybrid environment where Rust or C++ contracts can interact with existing Solidity protocols seamlessly.

By introducing WASM, Arbitrum expands the developer pool beyond Solidity specialists. Developers can leverage existing codebases and mature libraries from the broader systems programming community. For more details on the technical implementation, see the Arbitrum Stylus documentation. This approach unlocks new developer talent and substantial performance gains for specific use cases 1.

EVM vs Stylus: Core technical differences

The choice between Ethereum Virtual Machine (EVM) and Arbitrum Stylus comes down to how you want to execute code. EVM relies on a stack-based virtual machine that processes Solidity or Vyper bytecode. Stylus introduces a new execution layer that runs WebAssembly (WASM) modules, allowing developers to use systems languages like Rust and C++.

This architectural shift changes the rules for performance and cost. EVM is mature and secure but constrained by gas limits that make complex computations expensive. Stylus optimizes for speed and lower gas usage by leveraging the efficiency of native machine code compiled via WASM. According to Arbitrum’s documentation, Stylus enables writing EVM-compatible smart contracts in languages that produce WASM output, bridging the gap between high-level security and low-level performance [[src-serp-1]].

Language and Compilation

EVM is tightly coupled with Solidity and Vyper. These languages compile to EVM bytecode, which is interpreted by the virtual machine. Stylus supports Rust and C++, which compile to WASM. This allows developers to use existing ecosystems and libraries from the broader systems programming world. The Stylus Rust SDK provides tools to write contracts that are ABI-equivalent to Solidity, ensuring compatibility with existing Ethereum tooling while offering the performance benefits of Rust [[src-serp-8]].

Performance and Gas Efficiency

Gas costs in EVM scale linearly with the complexity of operations. Complex logic, such as heavy cryptographic proofs or large data processing, becomes prohibitively expensive. Stylus reduces gas costs for compute-heavy tasks by executing WASM modules more efficiently. The WASM runtime is optimized for speed, allowing complex logic to run with fewer gas units compared to equivalent Solidity implementations.

Security Models

EVM benefits from decades of scrutiny. Its security model is well-understood, with extensive auditing practices and a vast library of verified contracts. Stylus introduces new security considerations. While WASM is memory-safe, the security of Stylus contracts depends on the correctness of the Rust or C++ code and the WASM runtime itself. Developers must ensure that their native code does not introduce vulnerabilities that were previously mitigated by the EVM’s restrictive environment.

FeatureEVMStylus
LanguagesSolidity, VyperRust, C++
BytecodeEVM BytecodeWebAssembly (WASM)
Gas EfficiencyStandardHigher for compute-heavy tasks
MaturityMature, widely auditedNewer, evolving ecosystem
CompatibilityNative EthereumEVM-compatible ABI

When to Choose Which

Use EVM for standard DeFi protocols, NFTs, and governance systems where the ecosystem is mature and security is paramount. The vast tooling support and established best practices make EVM the safer default for most applications. Choose Stylus for applications requiring heavy computation, such as zero-knowledge proof verification, complex simulations, or large-scale data processing. The performance gains and lower gas costs can make previously unfeasible applications viable.

Why Rust and C++ matter for developers

The EVM’s dominance has long been tied to a single language: Solidity. This created a talent bottleneck. While millions of engineers write in Rust, C, or C++, they were largely excluded from the blockchain space. Arbitrum Stylus breaks this barrier, opening the door for a massive new wave of developers to build on-chain.

This isn't just about convenience; it's about access. By supporting systems languages, Stylus taps into a global pool of engineers who already understand memory management and low-level optimization. As noted in the official Arbitrum documentation, this allows teams to "unlock new developer talent" that was previously unreachable. You are no longer limited to the subset of engineers who specialize in Solidity.

Beyond talent, these languages offer performance and safety advantages that Solidity cannot match. Rust provides memory safety without a garbage collector, preventing common bugs like buffer overflows. C++ allows for high-performance computation that would be prohibitively expensive in EVM opcodes. This means complex logic can run faster and cheaper, leveraging the full power of modern programming paradigms.

The result is a more robust ecosystem. Developers can reuse existing libraries and tools from the broader software industry. This reduces development time and increases security by relying on battle-tested codebases rather than writing everything from scratch. Stylus effectively bridges the gap between traditional software engineering and decentralized applications.

When to choose Stylus over standard EVM

The decision to use Arbitrum Stylus hinges on performance requirements that exceed the limits of the Ethereum Virtual Machine (EVM). While standard EVM remains the industry standard for general-purpose smart contracts, Stylus offers a distinct advantage for applications demanding higher throughput and lower latency. If your protocol involves complex cryptographic operations or requires sub-millisecond execution times, Stylus provides the necessary computational power.

High-Frequency Trading and DeFi

For decentralized finance (DeFi) applications, speed is often the difference between profitability and slippage. Stylus enables high-frequency trading strategies by allowing developers to write execution logic in Rust or C++. These languages produce WebAssembly (Wasm) output, which executes significantly faster than EVM bytecode. This efficiency reduces transaction costs and latency, making it ideal for order books, automated market makers, and other trading-heavy architectures where every millisecond counts.

Arbitrum Stylus architecture showing EVM and WASM lanes

Complex Cryptography and ZK Proofs

Standard EVM is computationally expensive for heavy cryptographic operations. Verifying zero-knowledge proofs (ZKPs) or running complex elliptic curve pairings can consume vast amounts of gas, often making such operations economically unviable on-chain. Stylus allows developers to implement these cryptographic primitives in Rust or C++, leveraging optimized libraries that are orders of magnitude faster than their Solidity equivalents. This makes Stylus the superior choice for rollups, privacy-preserving protocols, and any application relying heavily on advanced cryptography.

Existing Codebases and Developer Ecosystem

Stylus also benefits teams with existing codebases in Rust or C++. Instead of rewriting legacy systems in Solidity, developers can port their existing logic directly to Arbitrum. This reduces development time and minimizes the risk of bugs introduced during language translation. As noted by Offchain Labs, Stylus enables users to deploy programs written in popular programming languages, opening the door for a broader range of developers to participate in the Arbitrum ecosystem.

Security and fraud proofs in Stylus

The most common concern when moving beyond the EVM is whether new execution environments compromise security. Arbitrum addresses this by extending its interactive fraud proof system to cover Stylus code. This means that whether a contract is written in Solidity or compiled Rust and C++ into WASM, it is protected by the same rigorous challenge mechanism.

This architecture ensures that Stylus does not operate in a security vacuum. The L2 engine can verify WASM execution using the same interactive proofs that secure native EVM transactions. As noted in the official Stylus documentation, this prover allows Arbitrum to maintain its security guarantees while supporting more efficient programming languages.

For developers, this means you get the performance benefits of low-level languages without sacrificing the trust model. The network remains secure because any invalid state transition can be challenged and proven wrong on-chain, just as it would be for traditional Solidity contracts.

Common questions about Arbitrum Stylus

Developers often ask how Stylus fits into the existing EVM ecosystem. The short answer is that it doesn't replace Solidity; it runs alongside it. You can deploy Stylus contracts in Rust or C++ while keeping your existing Solidity contracts and tooling intact.

Can I use Solidity with Stylus?

Yes. Arbitrum Stylus is designed to be EVM-compatible. This means you can write smart contracts in Rust or C++ that compile to WebAssembly (WASM) and still interact with the Ethereum Virtual Machine (EVM) as if they were Solidity contracts. You can even mix and match: a single transaction can invoke both a Solidity contract and a Stylus contract in the same call stack. This allows you to adopt new languages for specific performance-critical parts of your application without rewriting your entire codebase.

Do I need to learn a new SDK?

Not necessarily, but you will need language-specific tooling. For Rust developers, the Arbitrum Stylus Rust SDK provides the necessary abstractions to write Solidity ABI-equivalent contracts. It handles the low-level details of WASM compilation and EVM interaction, so you can focus on application logic rather than blockchain infrastructure. If you are coming from a C++ background, similar bindings exist to help you bridge your code to the EVM environment.

How does Stylus handle gas and execution?

Stylus contracts execute in a WASM environment, which has different performance characteristics than the EVM. While gas costs are still measured in gas units to maintain compatibility with existing dApps, the underlying execution engine is optimized for speed. This means computationally heavy operations, like complex cryptography or state transitions, can run significantly faster and cheaper in Stylus than in pure Solidity. However, you should still profile your contracts carefully, as WASM execution models differ from the EVM's stack-based architecture.