![]()
The onboarding and education layer for Solana builders.
<a href="https://learnsol.site"><strong>Live Site</strong></a>
·
<a href="https://youtu.be/pM1zKL5CbhA"><strong>Demo</strong></a>
·
<a href="https://x.com/learndotsol"><strong>X</strong></a>
learn.sol is a free, open-source learning product for developers who want to understand Solana by building through the stack.
It is not a loose list of tutorials. The product connects structured modules, executable exercises, runtime-focused tools, AI-assisted documentation, and a publishable agent skill into one learning loop:
The goal is simple: help builders move from "I copied a Solana snippet" to "I can explain what accounts, signers, transactions, PDAs, token flows, and clients are doing."
The curriculum is organized around the real Solana developer stack:
| Module | Focus |
|---|---|
| Solana Foundations | CLI workflow, accounts, lamports, transactions, architecture, and a first devnet toolkit with @solana/kit. |
| Rust Foundations | Syntax, ownership, borrowing, structs, enums, collections, methods, and Solana-shaped Rust practice. |
| Anchor Programs | Local setup, program anatomy, constraints, PDAs, SPL Token, CPI, token minting, escrow, and ergonomics. |
| Solana Kit Clients | Wallet Standard, account reads, transaction messages, confirmation, Token-2022 flows, Anchor clients, transaction UX, and testing. |
All lesson content lives under content/ and is rendered through Fumadocs MDX.
The challenge system is content-first and currently ships a 30-exercise Rust track under content/challenges/rust.
Challenges support:
Key files:
lib/challenges/exercises.tsapp/challengesapp/api/challenges/run/route.tsapp/api/challenges/progress/route.tsapp/api/challenges/complete/route.tsRuntime Lab is an interactive Solana runtime simulator for beginners. Learners predict what the runtime checks, reveal account diffs, inspect logs, and debug failure modes like wrong signers, owner mismatches, and PDA seed errors.
Runtime Lab currently includes a Vault Bootcamp flow and saves signed-in user progress.
Key files:
Visual Builder lets learners sketch Solana program architecture with drag-and-drop blocks for programs, instructions, transactions, signers, accounts, PDAs, token mints, token accounts, and CPIs.
It also includes local graph persistence and Anchor export helpers.
Key files:
components/visual-builder/editor.tsxlib/visual-builder/blocks.tslib/visual-builder/export-anchor.tsapp/tools/visual-builderlearn.sol includes a documentation-aware chat route and LLM-friendly text endpoints:
/api/chat streams AI answers with a documentation search tool./llms.txt lists the docs corpus with canonical URLs and MDX links./llms-full.txt returns a full text dump of the learning content./learn/<slug>.mdx exposes markdown-friendly routes for individual docs pages.Embeddings and search data use Postgres + pgvector.
This repo ships a publishable Agent Skill that turns coding agents into Solana teachers.
Install it with:
npx skills add Some1Uknow/learn-solana --skill learn-solana
The skill lives in skills/learn-solana. It teaches Solana concepts from first principles with examples, diagrams, tables, exercises, and temporary HTML explainers.
app/ App Router pages, API routes, OG images, tools, and docs endpoints
components/ UI, layout, auth, challenge, learn, and visual-builder components
content/ MDX curriculum and challenge content
data/ Module catalog data used by the modules UI
drizzle/ Database migrations
hooks/ Client hooks for auth, progress, and tool state
lib/ Auth, DB, challenge, runtime-lab, visual-builder, SEO, AI, and Solana helpers
public/ Brand assets, logos, social images, and static media
scripts/ Migration, SEO, and docs ingestion scripts
skills/learn-solana/ Publishable Solana teaching agent skill
docs/ Architecture notes and project documentation
pnpm install
Create a local .env file:
POSTGRES_URL="postgresql://user:password@localhost:5432/learnsol"
NEXT_PUBLIC_SITE_URL="http://localhost:3000"
NEXT_PUBLIC_PRIVY_APP_ID="your-privy-app-id"
NEXT_PUBLIC_PRIVY_CLIENT_ID="your-privy-client-id"
PRIVY_APP_ID="your-privy-app-id"
PRIVY_APP_SECRET="your-privy-app-secret"
OPENAI_API_KEY="your-openai-api-key"
# Optional
NEXT_PUBLIC_CLARITY_ID=""
NEXT_PUBLIC_ENABLE_REACT_SCAN=""
pnpm dev
Open http://localhost:3000.
Generate migrations:
pnpm db:generate
Apply migrations through the safe migration wrapper:
pnpm db:migrate
Open Drizzle Studio:
pnpm db:studio
If lesson content changes and you need fresh embeddings:
pnpm ingest-docs
This requires POSTGRES_URL and OPENAI_API_KEY.
| Command | Purpose |
|---|---|
pnpm dev |
Start the local Next.js dev server with Turbopack. |
pnpm build |
Build the Next.js app. |
pnpm start |
Start the production Next.js server. |
pnpm seo:check |
Validate SEO route assumptions. |
pnpm db:generate |
Generate Drizzle migrations. |
pnpm db:migrate |
Apply migrations with the safe wrapper. |
pnpm db:studio |
Open Drizzle Studio. |
pnpm ingest-docs |
Rebuild the docs search corpus and embeddings. |
pnpm preview |
Build and preview with OpenNext Cloudflare. |
pnpm deploy |
Build and deploy with OpenNext Cloudflare. |
pnpm knip |
Check for unused files, dependencies, and exports. |
pnpm find:unused |
Run Next unused checks. |
| Route | Purpose |
|---|---|
/ |
Product home page. |
/modules |
Module catalog. |
/modules/[moduleId] |
Module detail pages backed by data/contents-data.ts. |
/learn/[[...slug]] |
Fumadocs MDX lesson reader. |
/challenges |
Challenge track catalog. |
/challenges/[track] |
Challenge list for a track. |
/challenges/[track]/[slug] |
Challenge workspace with editor and validation. |
/tools |
Tool catalog. |
/tools/runtime-lab |
Runtime Lab program list. |
/tools/runtime-lab/[programId] |
Runtime Lab interactive program flow. |
/tools/visual-builder |
Visual Solana Builder. |
/branding |
Brand kit page. |
/partner |
Partner page. |
/llms.txt |
LLM-readable docs index. |
/llms-full.txt |
Full docs content dump for LLMs. |
To add or edit a lesson:
.mdx file in the right module folder under content/.meta.json.data/contents-data.ts.pnpm ingest-docs if search embeddings need to be refreshed.To add a challenge:
content/challenges/<track>/.title, description, track, slug, order, difficulty, tags, starterCode, and optional executor settings.Contributions are welcome across curriculum, examples, UI, product flows, and infrastructure.
Start with CONTRIBUTING.md, but note that the current curriculum structure is module-based under content/solana-foundations, content/rust-foundations, content/anchor-programs, and content/solana-kit-clients.
MIT. See LICENSE.MD.
Built for Solana developers who want the model, not just the snippet.
$ claude mcp add learn-solana \
-- python -m otcore.mcp_server <graph>