Since 2009, CKEditor has been Drupal’s go-to solution for rich text editing and it’s done its job well. But as more Drupal sites go headless, decoupled, or omnichannel, HTML-based content is starting to show its age.

The new ProseMirror module for Drupal brings a modern, structured editing experience designed for this new era. One that’s easier to extend, cleaner to integrate, and far more flexible for frontends of every kind.

The Problem with HTML in a Headless World

HTML is great for rendering web pages, but it’s not ideal when your content needs to travel beyond Drupal. Here’s why traditional HTML-based fields can get in your way:

  • The HTML structure is rigid and not tailored for all use cases like custom frontends, emails, native apps, or digital signage.
  • Links point to internal Drupal routes, which collide with custom frontend routing.
  • Media is embedded as HTML tags that decoupled frontends can’t easily extract, optimize, cache and embed.
  • Full HTML support assumes every channel can render everything (it can’t).

If you’ve ever spent time cleaning up HTML for your API responses, writing {JSON:API} normalizers and virtual fields, or post-processing content for apps, you already know the pain.

ProseMirror: Structured Data, Not HTML

One of Drupal’s greatest strengths has always been its support for structured data to define any content model, store it cleanly, and expose it through powerful APIs. But when it comes to rich text, things have traditionally been different. CKEditor still store content as HTML, which quickly becomes a limitation once you start building headless or multi-channel experiences.

ProseMirror changes that. Instead of storing content as HTML, the new prosemirror Drupal module stores it as structured JSON data, describing what each element is (a paragraph, a heading, a link, a media item) rather than how it should look. That means:

  • Your frontends decide how to render content, not Drupal’s markup.
  • Links, media, and images can be routed and displayed exactly how you want.
  • Content stays clean, consistent, and channel-agnostic, ready for any API or frontend.

Made for editors: When changing something as fundamental as the rich text editor, it’s important to consider the impact on editors. ProseMirror keeps their experience familiar and intuitive so that it feels and behaves mostly like before, only much more flexible under the hood.

Three Common Problems, Solved

1. Adaptive Display Logic Across Frontends and Channels

HTML assumes a browser, but your content shouldn’t have to. With ProseMirror, rich text is stored as structured data, so developers can take full control of how elements and marks are rendered, whether in Drupal, Next.js, a mobile app, an email, or digital signage. The same content adapts perfectly to every context.

2. Flexible Navigation and Link Handling

Traditional CKEditor links rely on Drupal’s internal routes, which don’t always fit headless frontends or native apps. ProseMirror keeps links as data instead of static markup, giving you complete freedom to decide how and where they resolve: by path, ID, or custom navigation logic.

3. Full Control Over Media and Images

Static HTML embeds limit how you can render or optimize images and media. ProseMirror treats them as structured objects, making it easy to define how assets are requested, optimized, cached, or embedded for each frontend, from responsive web layouts to mobile or CDN-based delivery.

A Simple Switch

Worried about switching from CKEditor? Don’t be! ProseMirror comes with a built-in parser that automatically converts CKEditor HTML into structured data. You can install it, enable the prosemirror_defaults submodule, and switch your text format in minutes. Your existing content just works.

Made for Developers and Builders

ProseMirror is modular by design. You can:

  • Define your own elements and marks through simple configuration (e.g., info boxes, buttons, code blocks).
  • Control what’s allowed where for reliable, consistent content models.
  • Extend both the PHP side (Drupal plugins) and the JS side (editor logic).

The ProseMirror module also integrates neatly with modules like Linkit for autocomplete-assisted entity links and Drupal’s native {JSON:API} for structured content delivery:

ProseMirror API Example

While Content Sync sponsored the initial development and maintenance, the module and the underlying editor are 100% open source with no dual licensing or feature restrictions. That being said, ProseMirror also works beautifully with Content Sync’s Content Cloud to further simplify integrations for those wanting to level up their headless, decoupled, and omnichannel Drupal experience.

Ready for APIs, Extensibility, and the Future

HTML is structured, but it’s structured for browsers, not for APIs. ProseMirror takes Drupal’s commitment to structured content a step further by representing rich text as typed JSON objects, not markup meant for display. In other words, ProseMirror modernizes Drupal’s editing experience and aligns rich text with the same structured, API-first principles that make Drupal’s entity system so powerful.

Get Started

Try it today:

composer require drupal/prosemirror
drush en prosemirror prosemirror_defaults

Once enabled, assign the ProseMirror editor to your preferred text format, and you’re ready to go.

You’ll find all setup details and examples in the ProseMirror module documentation here.

Clean APIs. Consistent content. Limitless frontends.