GitHub

Anchor

Solana's most popular smart contract framework

lib.rs
Anchor.toml
#[account(mut)]
pub payer: Signer<'info>,
pub publisher: Signer<'info>,
pub rent: Sysvar<'info, Rent>,
pub system_program: Program<'info, System>,
pub token_program: Program<'info, Token>,

Getting Started

Introduction

Anchor is a framework for quickly building secure Solana programs.

Installation

Step-by-step guides to setting up your system and installing Anchor.

Intro to Solana

Brief intro to programming on Solana.

High-Level Overview

High-Level Overview of an Anchor program.

CLI reference

A CLI is provided to support building and managing an Anchor workspace.


What is Anchor

With Anchor you can quickly build secure Solana programs, sometimes called 'smart contracts', because:

  • Anchor writes various boilerplate for you such as (de)serialization of accounts and instruction data.
  • Anchor handles certain security checks for you, and allows you to succinctly define additional checks and keep them separate from your business logic.

Both of these aspects mean that instead of working on the tedious parts of raw Solana programs, you can spend more time working on what matters most, your product.

Twitter

Stay up to date on Twitter

Join the community

Discord Invitation