A modern, multiβtheme blogging platform
Typeβsafe Β· Modular Β· i18n Β· Productionβready
Features Β· Themes Β· Tech Stack Β· Structure Β· Quick Start
maddyBlog is an openβsource blogging platform with a multiβtheme engine, dragβdrop header/footer builder, Persian/English i18n, and AI integration. Built with Next.js 16, TypeScript, and PostgreSQL β every module is decoupled, typeβsafe, and productionβready.
β¦ 9 themes Β· Visual header/footer builder Β· AI content tools Β· i18n β¦
| π¨ MultiβTheme Engine | 9 themes (default, Madelin, Zoomg, Zoomji, DigiTech, GameVerse, PersonalBlog, NewsWire, EduPro) with runtime switching |
| π§© Header/Footer Builder | Dragβdrop visual builder with 14 element types, perβtheme configs, color customization |
| βοΈ RichβText Editor | Tiptapβpowered with slash commands, image upload, live preview, autosave |
| π Auth System | JWT (jose) with httpOnly cookies, bcrypt, roleβbased (USER / ADMIN) |
| π·οΈ Categories & Tags | Organize content with PostTag manyβtoβmany |
| π¬ Nested Comments | Threaded discussions with reply trees + inβmemory rate limiting + @mentions |
| π i18n | Persian (RTL) / English (LTR) with message files, admin UI in Persian |
| π€ AI Integration | Content generation via Anthropic, Gemini, Ollama providers |
| π FullβText Search | PostgreSQL to_tsvector / to_tsquery across title + content |
| π Trending Algorithm | views Γ 0.6 + comments Γ 0.4 + recency boost |
| β€οΈ Reactions | Like / Fire / Clap with toggle per user |
| π Bookmarks | Save posts for later |
| ποΈ View Tracking | Granular PostView analytics (visitorHash, referrer, userAgent) |
| π Analytics Dashboard | recharts charts, traffic sources, top posts table, daily stats |
| π¬ Stories & Slides | Instagramβstyle stories + hero slides with scheduling and ordering |
| π§ Newsletter | Email subscription with rate limiting |
| π₯ Follow System | Follow/unfollow with unique constraints + activity feed |
| π Notifications | Follow, comment, reaction, mention, publish β with admin bell + polling |
| π° Activity Feed | Timeline of followed users' actions |
| π€ Profile Pages | /users/[username] with bio, avatar, post list |
| ποΈ Admin Dashboard | Full admin panel: posts, comments, users, themes, media, plugins, settings |
| πΌοΈ Media Library | Upload, browse, copy URL, delete β grid view |
| π³ Docker | Multiβstage Alpine build + dockerβcompose with PostgreSQL 16 |
| π CI/CD | GitHub Actions β lint β typecheck β build on push/PR |
| Theme | Vibe | Directory |
|---|---|---|
| Default | Clean, minimalist | default |
| Madelin | Modern, feminine | madelin |
| Zoomg | Gaming, bold | zoomg |
| Zoomji | Tech, vibrant | zoomji |
| DigiTech | Digital, futuristic | digitech |
| GameVerse | Dark, immersive | gameverse |
| PersonalBlog | Clean cardβbased | personalblog |
| NewsWire | News portal style | newswire |
| EduPro | Educational, structured | edupro |
All themes share a responsive layout, support dynamic header/footer customization, and can be switched live from the admin panel.
π¦ All themes are published on the maddyblog-themes repo β install via the admin Marketplace tab.
π§© All plugins are published on the maddyblog-plugins repo β install via the admin Marketplace tab.
| Layer | Technology |
|---|---|
| π¨ Frontend | Next.js 16 Β· TypeScript 5.x Β· React 19 Β· TailwindCSS |
| βοΈ Backend | REST API Routes + Server Components |
| ποΈ Database | PostgreSQL Β· Prisma ORM v7 (driver adapters) |
| βοΈ Editor | Tiptap (Slash commands, image upload, live preview) |
| β Validation | Zod v4 |
| π Auth | JWT via jose Β· bcryptjs Β· httpOnly cookies |
| π i18n | Custom provider with message files (fa/en) |
| π€ AI | Anthropic Β· Gemini Β· Ollama providers |
| π Charts | recharts |
| π§Ή Dev Tools | ESLint Β· Prettier Β· Husky Β· lintβstaged Β· Vitest |
| π³ Deploy | Docker Β· dockerβcompose Β· GitHub CI |
maddyBlog/
βββ prisma/ # Schema, migrations & seed
βββ src/
β βββ app/
β β βββ (admin)/ # Admin dashboard (15 pages)
β β βββ api/ # 25+ REST endpoints
β β βββ posts/ # Public blog pages
β β βββ categories/ # Category pages
β β βββ tags/ # Tag pages
β β βββ search/ # Search page
β β βββ users/ # Profile pages
β βββ components/
β β βββ admin/ # Admin UI (Header, Sidebar, etc.)
β β βββ blog/ # PostCard, CommentForm, SearchBar
β β βββ editor/ # Tiptap editor, toolbar, slash commands
β β βββ header-footer/ # Dynamic header/footer renderer + elements
β β βββ shared/ # ImageSlider, StoriesBar
β β βββ social/ # FollowButton, NotificationBell, ActivityFeed
β β βββ ui/ # Reusable UI primitives
β β βββ seo/ # StructuredData (JSONβLD)
β βββ themes/ # 9 theme packages (100+ components)
β β βββ default/
β β βββ madelin/
β β βββ zoomg/
β β βββ zoomji/
β β βββ digitech/
β β βββ gameverse/
β β βββ personalblog/
β β βββ newswire/
β β βββ edupro/
β βββ features/ # Domain modules (auth, post, comment)
β βββ services/ # Business logic (analytics, search, etc.)
β βββ lib/ # prisma, jwt, errors, logger, ai providers
β βββ i18n/ # i18n provider + message loading
β βββ cli/ # Developer CLI tool
βββ messages/ # i18n JSON files (fa.json, en.json)
βββ tests/ # Vitest unit tests
βββ docs/ # Architecture docs
βββ public/ # Static assets
βββ .github/ # CI workflows & templates
# clone
git clone https://github.com/Maddyrampant/maddyBlog.git
cd maddyBlog
# install
npm install
# setup env
cp .env.example .env
# generate prisma client
npx prisma generate
# run migrations (needs PostgreSQL)
npx prisma migrate dev
# seed (optional)
npm run seed
# start
npm run devNeeds a PostgreSQL instance β set
DATABASE_URLin.env
DATABASE_URL=postgresql://user:password@localhost:5432/maddyblog
JWT_SECRET=your-super-secret-key-change-in-production
NEXT_PUBLIC_APP_URL=http://localhost:3000
LOG_LEVEL=info| command | does |
|---|---|
npm run dev |
start development server |
npm run build |
production build |
npm run lint |
lint all files |
npm run typecheck |
TypeScript type checking |
npm run test |
run Vitest tests |
npm run seed |
seed database |
npm run db:studio |
open Prisma Studio |
npm run dev:cli |
developer CLI tool |
MIT β see LICENSE
built with love by a girl who codes
Maddyrampant Β© 2026