Cette page est affichée en anglais. Une traduction française est en cours.
SkillsMay 9, 2026·3 min de lecture

Wagtail — The Flexible Django Content Management System

Wagtail is an open-source CMS built on Django that gives developers full control over frontend design while providing editors with an intuitive page-editing interface.

Prêt pour agents

Cet actif peut être lu et installé directement par les agents

TokRepo expose une commande CLI universelle, un contrat d'installation, le metadata JSON, un plan selon l'adaptateur et le contenu raw pour aider les agents à juger l'adaptation, le risque et les prochaines actions.

Native · 98/100Policy : autoriser
Surface agent
Tout agent MCP/CLI
Type
Skill
Installation
Single
Confiance
Confiance : Established
Point d'entrée
Wagtail CMS Overview
Commande CLI universelle
npx tokrepo install 160d7268-4ba2-11f1-9bc6-00163e2b0d79

Introduction

Wagtail is a CMS built on top of Django that separates content modeling from presentation. It gives developers freedom to build any frontend while providing content editors with a streamlined admin interface featuring inline editing, image management, and workflow approvals.

What Wagtail Does

  • Provides a tree-based page model with customizable content types via Django models
  • Offers StreamField for flexible block-based content composition
  • Includes a built-in image library with focal-point cropping and renditions
  • Supports content workflows with moderation, revisions, and scheduled publishing
  • Delivers a fast search backend with Elasticsearch or database-level search

Architecture Overview

Wagtail extends Django's ORM to create a hierarchical page tree using django-treebeard. Each page type is a Django model subclass with fields exposed in the admin. StreamField stores structured content as JSON, rendered through block templates. The admin UI is a React-based SPA communicating with Django views. Media assets are managed through a pluggable storage backend compatible with S3 and local filesystems.

Self-Hosting & Configuration

  • Install via pip and scaffold a project with wagtail start
  • Configure the database in Django settings (PostgreSQL recommended for production)
  • Set up media storage with django-storages for S3 or equivalent cloud storage
  • Enable Elasticsearch for full-text search by configuring WAGTAILSEARCH_BACKENDS
  • Deploy behind Gunicorn or uWSGI with Nginx as the reverse proxy

Key Features

  • StreamField enables editors to compose pages from reusable content blocks
  • Built-in draft/publish workflow with multi-stage moderation support
  • Responsive image handling with automatic format conversion (WebP, AVIF)
  • Snippet system for reusable content fragments across pages
  • Full REST API and GraphQL support via wagtail-grapple for headless use

Comparison with Similar Tools

  • Django CMS — More tightly coupled to frontend templates; Wagtail offers greater developer flexibility
  • WordPress — PHP-based with a larger plugin ecosystem; Wagtail leverages Django's Python stack
  • Strapi — Headless-first API CMS; Wagtail provides both traditional and headless modes
  • Directus — Database-wrapper approach; Wagtail uses Django ORM with explicit content models
  • Payload CMS — TypeScript/Next.js based; Wagtail targets Python/Django teams

FAQ

Q: Can Wagtail be used as a headless CMS? A: Yes. Wagtail includes a built-in REST API and supports GraphQL via plugins for fully headless architectures.

Q: Does Wagtail work with any Django project? A: Yes. Wagtail can be added to an existing Django project as an app — it does not require starting from its project template.

Q: How does StreamField differ from rich text? A: StreamField stores structured blocks (images, quotes, code, embeds) as typed JSON, giving precise control over layout and rendering.

Q: What databases does Wagtail support? A: Any database Django supports — PostgreSQL, MySQL, SQLite. PostgreSQL is recommended for search and JSON field features.

Sources

Fil de discussion

Connectez-vous pour rejoindre la discussion.
Aucun commentaire pour l'instant. Soyez le premier à partager votre avis.

Actifs similaires