Skip to main content

First smart contract

Beginner
Getting started

Build Web3, DeFi, fully network-resident social media, games, enterprise apps, and just about anything else you can imagine. Your projects are immune to cyberattacks and unstoppable.

Open your terminal and deploy in minutes using these steps.

Prerequisites

Download and install Node.js.

1. Install the IC SDK.

sh -ci "$(curl -fsSL https://internetcomputer.org/install.sh)"

Confirm the IC SDK has been installed (you may need to open a new terminal window):

dfx --version

2. Create a new project.

The default project created by dfx is "Hello, world!"

dfx new hello --type=motoko

Creates a new Motoko project. Options are [motoko, rust, azle, kybra].

3. Deploy your project.

cd hello
dfx deploy --playground

4. Interact with your project.

Open the URL in your web browser that dfx returned after deploying your project.

Congratulations, you just created your first internet-native dapp!