Skip to main content
Version: 5.24.3

What is Starknet.js ?

Starknet.js is a library that helps to connect your website or your Decentralized Application (DAPP) to the blockchain-based Starknet network, using JavaScript / TypeScript language.

Overview​

Some important topics that have to be understood:

Understand what is Starknet and how it works is necessary. Then, you can learn how to interact with it using Starknet.js. So, at this stage, you should be aware of the content of the Starknet official doc and the Starknet Book.

  • Only the Provider object is talking directly to the network - your DAPP will talk mainly to Account and Contract objects. You will define with the Provider with which network you want to work. You can ask the Provider for some low-level data of the network (block, timestamp, ...).
  • Signer and Utils objects contain many useful functions for interaction with Starknet.js.
  • The Contract object is mainly used to read the memory of a blockchain contract.
  • The Account object is the most useful:
    • as a wallet, to store your tokens.
    • as a way to pay the fees to the network, and to be able to write in its memory.