FuelLabs /fuels-rs

Fuel Network Rust SDK

★ 42,942⑂ 1,359👁 121⑃ 1,048● 664▤ 121◈ 6
RustApache-2.0Created 2021-10-31fuellabs.github.io/fuels-rs
42,942
stars
+-3
1,359
forks
121
watchers
1,048
prs
664
issues
121
releases
6
discussions

README

fuels-rs






Rust SDK for Fuel. It can be used for a variety of things, including but not limited to:

- Compiling, deploying, and testing Sway contracts;
- Launching a local Fuel network;
- Crafting and signing transactions with hand-crafted scripts or contract calls;
- Generating type-safe Rust bindings of contract methods;
- And more, fuels-rs is still in active development.

 Documentation

See the fuels-rs book

 Features

- [x] Launch Fuel nodes
- [x] Deploy contracts
- [x] Interact with deployed contracts
- [x] Type-safe Sway contracts bindings code generation
- [x] Run Sway scripts
- [x] CLI for common operations
- [x] Local test wallets
- [ ] Wallet integration
- [ ] Events querying/monitoring

 FAQ

 What dependencies do I need?

- The latest stable Rust toolchain;
- forc and fuel-core binaries.

 How can I run the SDK tests?

First, build the test projects using forc:

shell
forc build --release --path e2e


Then you can run the SDK tests with:

shell
cargo test


You can also run specific tests. The following example will run all integration tests in types.rs whose names contain in_vector and show their outputs:

shell
cargo test --test types in_vector -- --show-output


 How to run WASM tests?

You need to have wasm32 as a target, if you don't already:

shell
 rustup target add wasm32-unknown-unknown


You also need wasm-pack, if you don't already:

shell
cargo install wasm-pack


Navigate to packages/wasm-tests and run wasm-pack test.

 What to do if my tests are failing on master

Before doing anything else, try all these commands:

shell
cargo clean
rm Cargo.lock
forc build --release --path e2e
cargo test


 Why is the prefix fuels and not fuel?

In order to make the SDK for Fuel feel familiar with those coming from the ethers.js ecosystem, this project opted for an s at the end. The fuels- family of SDKs is inspired by The Ethers Project.

 How can I run the docs locally?

Install mdbook by running:

shell
cargo install mdbook


Next, navigate to the docs folder and run the command below to start a local server and open a new tab in your browser.

shell
mdbook serve --open


You can build the book by running:

shell
mdbook build

Top issues

Discussions

Latest release

v0.77.0 v0.77.0 2026-04-06
What's Changed
 Feature/log id expose by @xgreenx in https://github.com/FuelLabs/fuels-rs/pull/1699
 Make IsUserAccountVariables cloneable by @ironcev in https://github.com/FuelLabs/fuels-rs/pull/1705
 chore: bump MSRV to 1.93 by @xgreenx in https://github.com/FuelLabs/fuels-rs/pull/1706
 chore(deps): Bump fuel-vm to 0.66.2 and  fuel-core to 0.48.0 by @ironcev in https://github.com/FuelLabs/fuels-rs/pull/1707
 Add multi-URL client connect method. by @its-saeed in https://github.com/FuelLabs/fuels-rs/pull/1702
 chore(version): bump to v0.77.0 by @ironcev in https://github.com/FuelLabs/fue

Snapshot: 2026-11-10T09:35:25Z · Data license Apache-2.0 · JSON