A sensible way to learn Solana development

Solana development becomes much easier once you separate three layers: the network model, the onchain program, and the client application. Beginners often jump straight into framework code without first understanding accounts and transactions, which makes debugging much harder later.

1LearnAccounts & transactions

Understand addresses, signers, owners, instructions and atomic execution.

2ExperimentPlayground & Devnet

Send transactions and deploy examples without touching production assets.

3BuildAnchor or native Rust

Create an onchain program and understand where its state lives.

4ConnectClient + wallet + RPC

Construct instructions and connect a user-facing application.

5HardenTest & review

Cover authorization, account constraints, edge cases and failure paths.

6OperateDeploy & monitor

Treat upgrades, keys, RPC, observability and incidents as production concerns.

Best starting point: the official Solana Quick Start uses Solana Playground so you can learn accounts, transactions, programs, PDAs and CPIs without first installing a local toolchain.

Programs are code. Accounts hold state.

A Solana program is executable code compiled to sBPF and stored in an executable account. Programs themselves are stateless; mutable application state lives in separate data accounts that are passed into instructions.

PROGRAMExecutable logic

The rules your application executes onchain.

ACCOUNTPersistent state

Balances, configuration and application data live here.

INSTRUCTIONOne requested operation

Names the program, required accounts and instruction data.

TRANSACTIONAtomic bundle

Contains one or more instructions plus signatures and recent blockhash data.

This separation is central to Solana. When a transaction declares which accounts it needs, the runtime can reason about which state may be read or written during execution.

Browser first, local environment second

There are two good ways to start. If you are learning, Solana Playground removes most setup friction. If you are building a serious project, move to a local environment once you understand the basics.

FASTEST START

Solana Playground

Browser-based development, testing and deployment with no local installation required.

Open Playground ↗
LOCAL TOOLCHAIN

CLI + Rust + Anchor

The current official installer sets up Rust, Solana CLI, Anchor CLI, Surfpool CLI, Node.js and Yarn. Windows users are directed to WSL.

Installation guide ↗
For production work, pin toolchain and dependency versions in your project rather than assuming every developer machine has the same global versions.

Anchor or native Rust?

Solana programs are primarily written in Rust. The official documentation distinguishes between Anchor, a higher-level framework, and native Rust, which gives you more direct control but requires more manual setup and boilerplate.

MORE CONTROL

Native Rust

  • Direct control over program structure
  • Useful for learning lower-level mechanics
  • More manual validation and serialization work
  • Useful when optimization or fine-grained control matters

The current official Rust-program documentation explicitly recommends beginners start with Anchor, while describing native Rust as a good fit for developers who want granular control or want to understand the underlying mechanics.

OFFICIAL QUICK START

Build your first program with Anchor

The current first-program tutorial uses an Anchor starter project and covers build, test and program structure.

First Program ↗

Design your account model before your instructions

On Solana, application architecture starts with accounts. Decide what state must persist, who is allowed to modify it and which program owns the data account.

Program Derived Addresses

A Program Derived Address (PDA) is a deterministic address derived from seeds and a program ID. PDAs are useful when a program needs predictable account addresses and program-controlled signing semantics without an ordinary private key.

Seed inputsDeterministic namingChoose stable, unambiguous seeds tied to your application model.
Program IDNamespaceThe same seeds under another program produce a different address.
PDAProgram-controlled addressThe program can sign for the PDA during a valid program invocation.
Security principle: never assume an account is trustworthy just because the client supplied it. Onchain programs must validate ownership, signers, expected addresses and any business constraints they depend on.

Cross-Program Invocations

A Cross-Program Invocation (CPI) lets one Solana program invoke an instruction in another program. This is a fundamental mechanism for composing applications from existing onchain programs.

CLIENTTransaction
→
PROGRAM AYour logic
→
CPIInvoke
→
PROGRAM BExisting capability

CPIs are powerful, but account privileges matter. Signer and writable privileges cannot simply be escalated by a called program. When a PDA controlled by the invoking program must sign, the runtime can authorize it from the PDA's seeds during the CPI.

Your frontend is not your program

The client layer constructs transactions, fetches state, connects to wallets and communicates through RPC. It should be treated as untrusted from the perspective of your onchain program: any important rule must be enforced onchain, not only in JavaScript.

UIReact / web / mobileUser experience and application state.
WALLETSigner connectionUser authorization and transaction approval.
SDKSolana Kit / client libraryBuild messages, addresses, instructions and RPC requests.
RPCNetwork interfaceRead state and submit signed transactions.
PROGRAMOnchain rulesAuthoritative validation and state changes.

For new TypeScript/JavaScript work, the current official Solana documentation recommends @solana/kit. Older examples using @solana/web3.js v1 are still widespread, so always check the date and library generation when following a tutorial.

RELATED GUIDE

Solana Tools

Our independent overview of wallets, RPC, Solana Kit, Rust clients, testing and infrastructure.

Explore Tools →

Test logic, authorization and integration separately

Good program tests do more than prove the happy path. They should also prove that unauthorized signers, wrong account owners, invalid PDAs and malformed inputs are rejected.

FASTUnit / in-memory tests

Exercise program logic quickly and repeatedly.

REALISTICLocal validator

Test transactions and program behavior against a local Solana cluster.

PUBLICDevnet integration

Verify wallet, RPC and deployment flows in a shared non-production environment.

FINALMainnet readiness

Only after controls, keys, monitoring and failure procedures are understood.

The official native Rust guide currently demonstrates testing with litesvm and also documents deployment against solana-test-validator. Solana's program examples repository includes examples in Anchor, native Rust and Pinocchio.

Deployment is a security decision

Deploying a program creates an onchain program account. Upgradeability depends on the loader and whether an upgrade authority remains configured. Current Solana documentation notes that programs deployed with the upgradeable loader can be upgraded while an upgrade authority exists; revoking that authority makes the program immutable.

BEFORE DEPLOYProgram ID

Know whether your client, PDAs and integrations depend on a stable program address.

ACCESSUpgrade authority

Protect it like production infrastructure. Decide who can authorize upgrades.

VERIFYBuild provenance

Keep source, releases and deployment artifacts reproducible and reviewable.

AFTER DEPLOYMonitoring

Watch transaction errors, logs, RPC dependencies and operational changes.

“Upgradeable” and “immutable” are governance and risk choices, not automatic quality labels. Teams should document their intended upgrade model and make it understandable to users.

Before real users and real value

  • Authorization: every privileged instruction validates the required signer and expected authority.
  • Account validation: owners, addresses, PDAs, writable status and relationships are checked onchain.
  • Arithmetic and edge cases: amounts, counters, conversions and boundaries are handled deliberately.
  • Upgrade keys: deployment and upgrade authorities are protected, backed up and intentionally governed.
  • RPC resilience: production behavior does not assume a public endpoint has guaranteed capacity.
  • Observability: failed transactions, program logs and infrastructure errors can be detected and investigated.
  • Dependency review: framework and SDK versions are pinned and monitored for migrations or security updates.
  • Independent review: high-value applications should consider professional security review before launch.

Where to go next

Frequently asked developer questions

What language is used for Solana smart contracts?

Solana calls smart contracts “programs.” They are primarily developed in Rust and compiled to Solana's sBPF execution format.

Should a beginner start with Anchor?

The current official Solana Rust-program documentation recommends Anchor for beginners because it reduces boilerplate and provides higher-level development patterns. Native Rust remains useful for deeper control and learning lower-level mechanics.

Do Solana programs store their own state?

Programs are stateless. Mutable state lives in separate data accounts that are passed to the program through instructions.

What is a PDA?

A Program Derived Address is a deterministic address derived from seeds and a program ID. It has no ordinary private key and can be authorized by its owning program under the runtime's PDA signing rules.

What should I use for JavaScript clients?

For new TypeScript and JavaScript applications, current official Solana documentation recommends @solana/kit. Existing codebases may still use the legacy @solana/web3.js v1 library.

Can I learn without installing anything?

Yes. Solana Playground is a browser-based development environment used by the official Quick Start for learning core concepts, deploying programs and experimenting with Devnet.

Sources and official documentation

This guide was checked against current first-party Solana documentation. Framework versions and recommended tooling change over time, so implementation decisions should always be verified against the current official docs.

Editorial note: Solana Factory is independent and is not affiliated with or endorsed by the Solana Foundation or Solana Labs. External links are provided for reference. Nothing on this page is financial advice.