cairostarter • Tests Lints GitHub GitHub package.json version

Forkable, Minimal Template for Starknet Projects.

Directory Structure

├─ Greeter"An example greeter contract"
├─ interfaces
│  ├─ IAccount"Account Interface"
│  ├─ IAggregatorV3"Chainlink V3 Aggregator Interface"
│  ├─ IERC20"ERC20 Contract Interface"
│  ├─ IERC165"ERC165 Contract Interface"
│  ├─ IERC721"ERC721 Contract Interface"
│  └─ IERC1155"ERC1155 Contract Interface"
├─ utils
│  ├─ Account"Stripped account"
│  ├─ Ownable"Minimal, ownable contract instance"
│  ├─ Context"Port of OZ's Solidity Context Abstraction"
│  └─ Pausible"Pausible Solidity Functionality"
└─ test_Greeter — "Test Script for the Greeter Contract"


First time?

Further installation instructions provided in the cairo-lang docs

Before installing Cairo on your machine, you need to install gmp:

sudo apt install -y libgmp3-dev # linux
brew install gmp # mac

If you have any troubles installing gmp on your Apple M1 computer, here’s a list of potential solutions.

For VSCode support:

Download cairo-0.6.2.vsix from

And run:

code --install-extension cairo-0.6.2.vsix

Set up the project

Clone the repository

git clone [email protected]:a5f9t4/cairostarter.git

cd into it and create a Python virtual environment:

cd cairostarter
python3 -m venv env
source env/bin/activate


Install the Nile dev environment and then run install to get the Cairo language, a local network, and a testing framework.

pip3 install cairo-nile
nile install


Compile the contracts

nile compile

Run tests




This project is still in a very early and experimental phase. It has never been audited nor thoroughly reviewed for security vulnerabilities. Do not use in production.

Please report any security issues you find by opening up an issue in this reposisitory.


Cairostarter Contracts are released under the AGPL-3.0-only.


View Github