Introduction to Grit
This course introduces Grit Framework — what it is, why it was created, how it compares to other tools, and what you'll learn in this course series. No coding in this course — just concepts and understanding. By the end, you'll know exactly what Grit gives you and whether it's right for your project.
Welcome to Grit
Welcome! You're about to learn a framework that will change how you build web applications. Whether you're a Go developer looking for a batteries-included solution, a JavaScript developer curious about Go, or a solo founder who needs to ship fast — Grit was built for you.
This is Course 0 — the conceptual foundation. There's no coding here, no terminal commands, no setup. Just ideas. You'll understand what Grit is, why it exists, what problems it solves, how it compares to frameworks you already know, and what you'll build throughout this course series.
What is Grit?
Grit is a full-stack meta-framework that combines Go (for the backend) with React (for the frontend). It gives you a complete, production-ready project in one command — with authentication, admin panel, file uploads, background jobs, email, and more already wired up and working.
What Grit is NOT:
- • Not a boilerplate — it's a living framework with a CLI that keeps helping you after the initial scaffold. Generate resources, sync types, deploy — all from the same tool.
- • Not a template — it generates real, customizable code you own. Every file is yours to modify, extend, or delete.
- • Not locked in — you can stop using Grit tomorrow and your code still works. It's standard Go, standard React, standard PostgreSQL. No proprietary runtime.
Challenge: Boilerplate vs Framework
In your own words, explain the difference between a boilerplate/template and a framework. Why is Grit a framework and not just a starter template? Think about what happens after the initial project is created.
The Problem Grit Solves
Every time you start a new project, you pay what we call the "Setup Tax" — weeks of work building infrastructure before you write a single line of business logic:
| Task | Typical Time |
|---|---|
| Authentication (JWT, password hashing, tokens) | 2–3 days |
| Admin panel (data tables, forms, dashboard) | 3–5 days |
| File uploads (S3, presigned URLs, image processing) | 1–2 days |
| Email (templates, sending, testing) | 1 day |
| Background jobs (queue, workers, retry logic) | 1–2 days |
| API documentation (OpenAPI spec, interactive UI) | 1 day |
| Security (rate limiting, WAF, headers) | 1 day |
| Docker setup (PostgreSQL, Redis, MinIO) | half day |
| Deployment (systemd, reverse proxy, TLS) | 1 day |
| Type safety between backend and frontend | ongoing pain |
Total: 2–4 weeks before you write a single line of business logic. And this happens every single time you start a new project.
grit new myapp and every item in that table is already done — configured, tested, and ready to use.Challenge: Your Setup Tax
Think about the last project you started. How long did you spend on setup and boilerplate before writing actual features? List the things you set up manually. How many of them are in the table above?
The Motivation — Why Grit Was Created
Grit was created by Muke JohnBaptist, a full-stack developer who was tired of rebuilding the same infrastructure for every project. Auth, admin panels, file uploads, background jobs — they should just work. Now they do.
The key insight: most web applications need the same 80% of infrastructure. Only 20% is unique business logic. Grit gives you the 80% so you can focus on the 20% that makes your app special.
Think about it: how many times have you debated whether to put your handlers in /controllers or /handlers? Whether to use camelCase or snake_case for API fields? Whether to structure your project by feature or by layer? Grit makes those decisions for you — good decisions, based on years of building production apps — so you can focus on building your product.
Challenge: The 80/20 Rule
Name 3 things that are the same in almost every web app (hint: authentication is one). For each, think about how much time you typically spend setting them up from scratch.
What Makes Grit Different
There are plenty of frameworks out there. Here's what sets Grit apart:
1. Choose Your Architecture
No other framework lets you pick between 5 architectures (single, double, triple, API, mobile) from the same CLI. Laravel is always single. Next.js is always single. Rails is always single. Grit adapts to your project.
2. Choose Your Frontend
Next.js for SEO, TanStack Router for speed. Same backend, same components, different routing. Pick what fits your project without changing anything else.
3. Code Generation That Works Both Ways
grit generate creates files. grit remove cleanly deletes them. No leftover code, no broken imports. Most generators only go one direction — Grit goes both.
4. Type Safety Across the Stack
Go types → TypeScript types → Zod schemas. Change a Go model, run grit sync, and your frontend types update automatically. No API contract drift. No runtime surprises.
5. One-Command Deployment
grit deploy builds, uploads, and configures your production server. No CI/CD needed to get started. From localhost to live in one command.
6. Built-in Security
Sentinel WAF, rate limiting, 2FA with TOTP — not plugins, not add-ons. Security by default, not security as an afterthought.
Challenge: Framework Comparison
Pick another framework you've used (Laravel, Rails, Next.js, Django, Express). List 3 things Grit does that your framework doesn't include out of the box.
The Tech Stack
Grit is opinionated about its tech stack. Every technology was chosen for a reason — performance, developer experience, community support, or all three. Here's the complete picture:
| Layer | Technology | Why |
|---|---|---|
| Backend | Go 1.21+ | Fast, compiled, type-safe |
| Web Framework | Gin | Most popular Go web framework |
| ORM | GORM | Auto-migration, relationships, hooks |
| Database | PostgreSQL / SQLite | Production / Desktop |
| Cache | Redis | In-memory speed, pub/sub, queues |
| Job Queue | asynq | Redis-backed, reliable, Go-native |
| File Storage | S3-compatible | AWS S3, Cloudflare R2, MinIO |
| Resend | Modern email API, great DX | |
| AI | Vercel AI Gateway | Multi-provider, streaming |
| Frontend | ||
| Router | Next.js 14+ / TanStack Router | SEO (Next) or SPA speed (TanStack) |
| UI Library | React | Largest ecosystem, most talent |
| Styling | Tailwind CSS + shadcn/ui | Utility-first, copy-paste components |
| Data Fetching | TanStack Query | Caching, refetching, optimistic updates |
| Validation | Zod | TypeScript-first schema validation |
| Forms | React Hook Form | Performant, minimal re-renders |
| Infrastructure | ||
| Monorepo | Turborepo + pnpm | Fast builds, shared packages |
| Security | Sentinel | WAF + rate limiting |
| Observability | Pulse | Tracing + metrics |
| DB Browser | GORM Studio | Visual database management |
| Desktop | Wails v2 | Native desktop apps with Go + React |
| Deployment | SSH + systemd + Caddy | Simple, reliable, auto-HTTPS |
"flex items-center gap-4 bg-blue-500 text-white".Challenge: Tech Stack Reasoning
For each layer in the tech stack (backend, ORM, database, frontend, styling, data fetching), explain in one sentence why that technology was chosen. Think about popularity, performance, and developer experience.
Who is Grit For?
Grit was designed for seven types of developers:
Who want a batteries-included framework like Laravel or Rails, but in Go. No more gluing together 15 libraries for every project.
Migrating to Go and wanting familiar patterns — single-app mode, artisan-like CLI, convention-driven structure.
Who want a proper backend instead of serverless functions. Real database connections, real background jobs, real performance.
Who want a structured monorepo with type safety instead of loosely connected services.
Building SaaS products who need to ship fast without cutting corners on quality or security.
Building client projects who need consistent, production-ready scaffolding for every engagement.
Learning full-stack development with a guided framework that teaches best practices by example.
Challenge: Find Your Persona
Which persona fits you best? Write down your background and what you hope to build with Grit. If none of these fit perfectly, describe your own persona — who are you and what do you need?
The 5 Architecture Modes
One of Grit's most powerful features is architecture flexibility. When you run grit new, you choose the architecture that fits your project. You'll learn each in detail in Course 1, but here's a quick overview:
Triple: Web + Admin + API
A monorepo with three apps — a public website, an admin dashboard, and a Go API. Best for SaaS apps, platforms, and anything that needs a separate admin experience.
Double: Web + API
A monorepo with two apps — a public website and a Go API. Best for simpler apps, blogs, and landing pages with a backend.
Single: One Go Binary
One Go binary with the frontend embedded. Like Laravel — everything in one place. Best for microservices and internal tools.
API Only: Go Backend
Just the Go API — no frontend. Best for mobile backends, headless APIs, and services consumed by other apps.
Mobile: API + Expo
Go API plus a React Native app built with Expo. Best for mobile-first products.
grit new-desktop for standalone Wails desktop apps with SQLite. It's a separate command because desktop apps have different requirements than web apps.Challenge: Choose Your Architecture
For each project idea below, which architecture would you choose and why?
- (a) A blog with an admin panel
- (b) A mobile fitness app
- (c) An internal company tool
- (d) A SaaS with billing and admin
- (e) A REST API for a mobile game
What Ships With Every Project
Every Grit project comes with 18 features out of the box. You'll learn each one in detail throughout this course series, but here's what you get on day one:
Challenge: Your Top 3
Which 3 features are you most excited about? Which ones would save you the most time compared to building them yourself? Write down your top 3 and estimate how many hours each would take to build from scratch.
The Grit Philosophy
Every framework has a philosophy — a set of beliefs that guide every decision. Here are the six principles behind Grit:
1. Convention over Configuration
Sensible defaults for everything. File structure, naming, API format — all decided. But every convention is overridable. You get speed by default and flexibility when you need it.
2. Code Generation over Runtime Magic
You own the code. When Grit generates a file, it's real code you can read, modify, and debug. No hidden runtime behavior, no magic annotations, no black boxes. If something breaks, you can see exactly why.
3. Batteries Included, Optionally Removable
Everything is included by default. Don't need email? Delete the email service file. Don't need AI? Remove the AI handler. Features are modular — removing one doesn't break the others.
4. Beautiful by Default
Every generated UI uses a premium dark theme with 100 pre-built components. Your app looks polished from minute one — not like a default Bootstrap template.
5. Monorepo Native
Shared types between Go and TypeScript. Change a model on the backend, run grit sync, and your frontend types update. One repo, one source of truth.
6. Vibe Coding Ready
Grit generates an AI skill file that teaches AI assistants (like Claude, Cursor, or Copilot) your project's structure, conventions, and patterns. Your AI pair programmer understands your project from day one.
Challenge: Philosophy Reflection
Which philosophy resonates most with you? Have you been burned by "runtime magic" or"configuration hell" before? Share a specific experience where one of these principles would have saved you time or frustration.
Comparison with Other Frameworks
How does Grit stack up against the most popular frameworks? Here's an honest comparison:
| Feature | Grit | Laravel | Rails | Next.js | T3 Stack | Django |
|---|---|---|---|---|---|---|
| Go Performance | Yes | No | No | No | No | No |
| React Frontend | Yes | No | No | Yes | Yes | No |
| Admin Panel | Yes | Nova ($) | Yes | No | No | Yes |
| Code Generator | Yes | Yes | Yes | No | No | No |
| Built-in 2FA | Yes | No | No | No | No | No |
| One-Cmd Deploy | Yes | Forge ($) | No | Vercel | No | No |
| Type-Safe API | Yes | No | No | Yes | Yes | No |
Challenge: Closest Competitor
Look at the comparison table. Which framework is closest to Grit? What does Grit offer that it doesn't? And what does that framework offer that Grit doesn't?
What You'll Learn in This Course Series
This course series has 9 courses that take you from zero to deploying a production-ready application. Here's the roadmap:
What Grit is, why it exists, and what you will learn (this course)
Install Grit, scaffold a project, explore the folder structure, run dev servers
Generate full-stack CRUD resources with one command
JWT, 2FA with TOTP, OAuth providers, role-based access
DataTable, FormBuilder, dashboard widgets, custom styles
S3-compatible storage, presigned URLs, image processing, MinIO
asynq job queue, cron scheduling, Resend email integration
Vercel AI Gateway, streaming responses, multi-provider support
grit deploy, systemd, Caddy reverse proxy, Docker, auto-HTTPS
By the end of this series, you'll be able to build and deploy a production-ready full-stack application with Go and React — including authentication, admin panel, file uploads, background jobs, AI features, and automated deployment.
Challenge: Your Project Idea
Write down one project idea you want to build with Grit. What architecture would you use (triple, double, single, API, or mobile)? What resources would you need to generate (e.g., users, products, orders)? Which of the 18 built-in features would your project need?
Summary
Here's everything you learned in this course:
- Grit is a full-stack meta-framework combining Go (backend) with React (frontend)
- It solves the "Setup Tax" — giving you 2-4 weeks of infrastructure in 30 seconds
- Grit was created to let developers focus on the 20% that makes their app unique
- It offers 5 architecture modes: triple, double, single, API, and mobile
- You can choose between Next.js and TanStack Router for the frontend
- Every project ships with 18 production-ready features out of the box
- The philosophy centers on convention over configuration and code you own
- Type safety flows from Go to TypeScript to Zod with grit sync
- Grit fills the gap of a Go + React full-stack framework
- The course series covers 9 courses from introduction to production deployment
Challenge: Prepare for Course 1
Before starting Course 1, prepare your development environment. Visit these links and bookmark them:
- Grit Docs: https://gritframework.dev/
- GitHub: https://github.com/MUKE-coder/grit
- YouTube: https://www.youtube.com/@GritFramework
- LinkedIn: https://www.linkedin.com/company/grit-framework
Star the GitHub repo, subscribe to YouTube, follow on LinkedIn. You're ready to start building.
Enjoying the course?
Help us grow — star us on GitHub, subscribe on YouTube, and follow on LinkedIn.