1. Introduction
Sui is a Layer-1 blockchain that uses an object-centric model to process transactions in parallel, enabling high throughput and instant finality while providing native primitives for building decentralized applications.
Developers choose Sui for several compelling reasons:
- Parallel execution - Transactions don’t wait in a single-file line, resulting in faster confirmation times
- Consumer-ready features - zkLogin (sign in with Google/Apple) and zkSend (share crypto via link) lower barriers to entry
- Move programming language - A secure, resource-oriented language designed specifically for blockchain development
- Built for scale - Optimized for data-heavy applications like gaming, NFTs, DeFi, and social apps
This guide walks you through setting up the complete Sui development environment on your local machine. By the end, you’ll have the Sui CLI installed, a local network running, and the essential developer tools configured to start building Move smart contracts and decentralized applications on Sui.
2. Prerequisites
Before installing Sui development tools, ensure your system meets the following requirements:
| OS | Architecture | Status |
|---|---|---|
| Linux | x86_64 (amd64) | ✅ Supported |
| Linux | aarch64 (ARM64) | ✅ Supported |
| macOS | x86_64 (amd64) | ✅ Supported |
| macOS | aarch64 (ARM64) | ✅ Supported |
| Windows | x86_64 (amd64) | ✅ Supported |
| Windows | aarch64 (ARM64) | Limited support (might or might not work) |
Operating System:
- macOS (Intel or Apple Silicon)
- Linux (Ubuntu 20.04+ or similar)
- Windows 10/11 (with WSL2 recommended)
Required Software:
- Rust toolchain (latest stable) - Required if building from source
- Git - For cloning repositories and version control
- Curl or Wget - For downloading installation scripts
Optional but Recommended:
- Docker - For containerized development environment
- Visual Studio Code - For Move language support and syntax highlighting
- Node.js (v16+) - For building dApps and frontends
System Resources:
- Minimum 4GB RAM (8GB+ recommended)
- At least 10GB free disk space
- Stable internet connection for downloading dependencies
If you plan to build from source using Cargo, make sure your Rust installation is up to date:
| |
3. Installing Sui CLI
The Sui CLI provides everything you need to develop, test, and deploy Move smart contracts. Choose the installation method that best fits your workflow.
Option 1: Using suiup (Recommended)
The easiest way to install and manage Sui binaries is through suiup, which handles version management across different networks.
For detailed suiup usage, see the official repository.
Option 2: Download Pre-built Binary
Download the latest release directly from GitHub:
- Visit the Sui releases page
- Download the binary for your OS (macOS, Linux, or Windows)
- Extract and move to your PATH
- Make it executable:
chmod +x sui(Unix-based systems)
Option 3: Package Managers
macOS (Homebrew):
| |
Windows (Chocolatey):
| |
Option 4: Build from Source (Advanced)
If you need the latest features or want to contribute, build from source using Cargo:
| |
Change mainnet to testnet or devnet if targeting those networks.
Verify Installation
Confirm Sui is installed correctly:
| |
You should see output like: sui 1.x.x-xxxxx
Initialize Sui CLI
Run the initialization command:
| |
The CLI will create a client.yaml configuration file at ~/.sui/sui_config/client.yaml (macOS/Linux) or %USERPROFILE%\.sui\sui_config\client.yaml (Windows).
When prompted:
- Connect to Sui Full Node? → Enter
Y(defaults to Testnet if no URL specified) - Sui full node server URL → Press Enter for Testnet, or specify:
https://fullnode.testnet.sui.io:443- Testnet (recommended for new developers)https://fullnode.devnet.sui.io:443- Devnet (advanced use, weekly data wipes)https://fullnode.mainnet.sui.io:443- Mainnet (requires real SUI tokens)http://0.0.0.0:9000- Localnet (if you’ve set up a local network)
- Key scheme selection → Choose encryption scheme:
- Press
0fored25519(recommended) - Press
1forsecp256k1 - Press
2forsecp256r1
- Press
Important: The CLI will display a recovery phrase. Store it securely and never share it - it provides access to all objects and tokens owned by the address.
4. Managing Sui Networks
Sui supports multiple networks for different development stages. Here’s how to manage and switch between them.
Understanding Network Options
| Network | RPC URL | Purpose |
| -------- | ----------------------------------- | ----------------------------------------------- |
| Testnet | https://fullnode.testnet.sui.io:443 | Recommended for development, stable environment |
| Devnet | https://fullnode.devnet.sui.io:443 | Cutting-edge features, weekly data wipes |
| Mainnet | https://fullnode.mainnet.sui.io:443 | Production network, requires real SUI tokens |
| Localnet | http://0.0.0.0:9000 | Your own local network for testing |
Managing Networks
View all configured networks:
| |
Switch between networks:
| |
Example: Switch to testnet:
| |
Add a new custom network:
| |
Example: Add mainnet:
| |
Check Active Address and Gas Objects
View all addresses in your keystore:
| |
Check the currently active address:
| |
List all gas objects you control:
| |
Get Test Tokens
To interact with Devnet or Testnet, you’ll need test tokens:
- Join the Sui Discord
- Complete verification steps
- Navigate to the faucet channel:
- #devnet-faucet for Devnet tokens
- #testnet-faucet for Testnet tokens
- Request tokens:
!faucet <YOUR_WALLET_ADDRESS>
Alternatively, use the Sui CLI faucet command (if available):
| |
5. Developer Tooling
Enhance your development workflow with these essential tools and extensions.
Move Analyzer for VS Code
The Move Analyzer extension provides syntax highlighting, code completion, and inline error checking for Move language development.
- Install Visual Studio Code
- Install the Move extension from the VS Marketplace
- Add Sui wallet address compatibility:
| |
This enables proper support for Sui’s address format in the analyzer.
Docker Development Environment (Optional)
For a consistent, isolated development environment:
- Install Docker
- Pull the official Sui Docker image:
| |
- Start and access the container:
Note: If the Docker image is incompatible with your CPU architecture, start with a base Rust Docker image appropriate for your system and install Sui manually.
Essential Resources
Sui Explorer: View transactions, objects, and network activity
- Devnet: https://devnet.suivision.xyz/
- Testnet: https://testnet.suivision.xyz/
- Mainnet: https://suivision.xyz/
Sui Documentation: https://docs.sui.io
Move by Example: https://move-book.com/
Sui GitHub: https://github.com/MystenLabs/sui
6. Testing and Deployment
Once your development environment is set up, you can start building and testing Move smart contracts.
Create a New Move Project
Initialize a new Move package:
This creates a basic project structure with:
Move.toml- Package manifestsources/- Your Move source filestests/- Unit tests
Compile Your Move Code
Build your Move package:
| |
This compiles your code and checks for errors. The Move compiler is included in the Sui binary.
Run Unit Tests
Execute tests defined in your Move modules:
| |
Add the --coverage flag to generate coverage reports:
| |
Publish to Network
Deploy your package to the active network:
| |
The command above will:
- Compile your package
- Create a publish transaction
- Execute it on the connected network (devnet/testnet/mainnet)
- Return the package ID for future interactions
Important: Make sure you have sufficient gas tokens on the active network before publishing.
Interact with Published Packages
Call functions from your published package:
| |
For detailed CLI reference, see the official Sui CLI documentation.
7. Troubleshooting
Common issues you might encounter and how to resolve them.
Installation Issues
Problem: sui: command not found
Solution: Ensure the Sui binary is in your PATH:
Problem: Rust compiler errors during cargo install
Solution: Update Rust to the latest stable version:
Build Errors
Problem: Missing dependencies or compilation failures
Solution:
- Check your
Move.tomlfor correct dependency declarations - Clean the build cache and rebuild:
Problem: Module resolution errors
Solution: Ensure your module addresses in Move.toml match the package configuration:
Network Configuration Issues
Problem: Cannot connect to network or RPC errors
Solution: Verify your network configuration:
Problem: Transaction failures due to insufficient gas
Solution: Request test tokens from the faucet or check your gas balance:
| |
Getting Help
If you encounter issues not covered here:
- Check the official troubleshooting guide
- Visit Sui GitHub Issues
- Ask in Sui Discord support channels
- Search Sui Developer Forums
8. Wrap-up
You’ve successfully set up a complete Sui development environment. Let’s recap what you’ve accomplished:
What You’ve Set Up:
- Sui CLI installed and configured
- Network connections (Devnet, Testnet, or local)
- Development tools (Move Analyzer, optional Docker environment)
- Understanding of basic CLI commands and workflows
Next Steps:
Build Your First Move Contract
- Follow the Sui Move by Example tutorials
- Start with simple modules and gradually increase complexity
- Experiment with Sui’s unique features (object model, parallel execution)
Connect to Testnet
- Get testnet tokens from the Discord faucet
- Deploy a package to testnet
- Test your contracts in a production-like environment
Explore Advanced Features
- Learn about zkLogin for seamless user authentication
- Experiment with zkSend for easy asset transfers
- Build consumer-facing dApps leveraging Sui’s UX primitives
Join the Community
- Sui Discord - Get help and connect with developers
- Sui Developer Forums - Technical discussions
- Sui GitHub - Contribute to the ecosystem
Recommended Learning Resources:
- Official Sui Documentation
- Sui Move Introduction Course
- Move Book - Deep dive into Move language
Happy building on Sui!
