Create Your Project by Using ink!

Let's make a folder for your project. We are going to use the ink! CLI to help us with this.

cargo contract new my_contract

This command creates a new folder named my_contract .

cd my_contract

This folder contains a Cargo.toml file and a file. The file is an example of a very simple ink! smart contract. When writing your own smart contracts, feel free to edit the files accordingly.


An off-chain test environment is provided by ink! to quickly test our code. First, let's build the files.

cargo +nightly build

Then to run the test,

cargo +nightly test

You should see the output of 2 successful tests in your command line.

Any questions? Feel free to ask us.