An AI assistant in CKEditor is a toolbar button that brings AI capabilities like rewrite, translate, summarize, and generate actions into Drupal's text editor. Editors can simply highlight text, pick an action, and get a result without leaving the editing screen. 

Behind it sits the Drupal AI module. It is an open-source framework that connects Drupal to large language model providers like OpenAI, Anthropic, and self-hosted Ollama through a single abstraction layer. Nearly 14,000 sites report using it, according to Drupal.org* (April 2026).

Key Takeaways

  • Setup is a UI task.
  • The module you choose has compliance consequences.
  • Content leaves your server when editors use AI.
  • Review-before-publish is the control that matters.

The AI Assistant dropdown in CKEditor, showing available actions for the selected text.

What is CKEditor in Drupal?

CKEditor 5 is the rich text editor that ships with Drupal core. It powers the body field on every content edit form: the toolbar, the formatting buttons, the editing surface your team already works in daily. Built by CKSource, it became Drupal's default editor with Drupal 10 in 2022, replacing CKEditor 4, which reached end of life in June 2023.

Under the hood, it is a plugin-based JavaScript framework rather than a single monolithic editor. Every toolbar button, from bold to image embeds, is a plugin. That architecture is what makes an AI assistant possible: the AI button slots in the same way any other button does.

Drupal manages all of this through text formats. Each format (Basic HTML, Full HTML, or your custom ones) carries its own toolbar configuration and its own rules about who can use it. That per-format setup is the exact mechanism every AI integration below hooks into.

Which module(s) add an AI Assistant to CKEditor?

Four options exist. They are not interchangeable, and the choice has data governance consequences.

  • AI CKEditor is a free submodule of the Drupal AI module (previously standalone, now absorbed into the main module). It gives you full control over your LLM provider, your prompts, and your infrastructure. This is the right starting point for most teams.
  • CKEditor AI arrived for Drupal with the CKEditor 5 Premium Features module v1.8.0 in March 2026. It requires a commercial CKEditor licence. AI requests route through CKSource's managed backend - not your Drupal server - and it supports OpenAI, Anthropic, and Azure. Worth evaluating if you already pay for CKEditor's commercial plan; not the right choice if data routing is a concern.
  • AI Automators handles background tasks: generating metadata, auto-tagging, and evaluating content using Drupal's plugin system. It is not editor-facing in the same way - it solves a different problem.
  • Field Widget Actions adds AI actions (rewrite, translate, summarize) directly on content edit forms, outside the CKEditor body.

How do you add an AI Assistant?

Step 1: Enable the module

composer require drupal/ai
drush en ai ai_ckeditor

The AI CKEditor integration module enabled on the Drupal modules page.

Step 2: Configure a provider

Go to Administration → Configuration → AI → AI Providers and add your credentials — an API key for a commercial provider, or the local endpoint URL if you are running Ollama. The AI module uses a provider-agnostic abstraction layer, so switching providers later does not require rebuilding your configuration.

The AI Providers configuration page showing OpenAI Authentication.

Step 3: Add the AI button to your toolbar

Go to Administration → Configuration → Content authoring → Text formats, edit your editorial format, and drag the AI Assistant button into the CKEditor toolbar. Enabling AI per text format means you can give senior editors access while withholding it from contributors.

The CKEditor toolbar configuration showing the AI button in the active toolbar.

Step 4: Configure AI actions per text format

Under the AI Tools vertical tab on the text format settings page, configure the modal dialog dimensions and choose which actions are available for that format. Each action has a system prompt you write and own. The model receives only what you configure.

The AI Tools vertical tab showing modal dialog configuration options.

The "Generate with AI" action configuration with provider selection and system prompt field.

The full list of available AI actions: Tone, Reformat HTML, Summarize, Help and Support, Translate, Fix spelling, Modify with a prompt.

Where does your content go when an editor uses AI?

When an editor clicks an AI action, the request routes to your Drupal server first. The server makes the call to your configured provider, receives the response, and returns it to the editor. Your API credentials never reach the browser. The content does reach whichever provider you configure - but from your infrastructure, not from the editor's machine.

For most organizations, this is acceptable: editors are typically working with unpublished draft text. It is no different from an editor pasting a paragraph into ChatGPT manually, except that the routing is controlled and logged.

For healthcare, government, and higher education, the "typical draft" assumption often breaks down. A constituent name, a patient identifier, or protected data can end up in the AI input. The module does not know what is sensitive.

For organizations where data residency is a hard requirement, Ollama is the answer. The ai_provider_ollama module connects Drupal's AI Core to a self-hosted Ollama instance. Configure it at Administration → Configuration → AI → AI Providers → Ollama. No content reaches a third-party API. The trade-offs are model quality relative to commercial APIs and the overhead of running and updating the model locally.

How do you keep AI-assisted editing under control?

  • Enforce review before publishing - This is not an AI setting - it is your existing Drupal content moderation workflow. If editors can self-publish, AI-assisted content goes live without review. Verify your moderation workflow is enforced at the content type level before enabling AI for any role.
  • Use role-based access - AI actions are available per text format. Assign text formats to roles deliberately. A contributor on a basic format sees no AI options. A senior editor sees the configured action set. Configure access at rollout and expand from there.
  • Enable AI Logging - The ai_logger submodule records every request - user, action, provider, model, and token count. For organizations with audit requirements, this is essential. For everyone else, it is still the fastest way to understand usage patterns early.
  • Write specific system prompts - Your prompts are your guardrails. A prompt that instructs the model not to fabricate sources or invent statistics reduces casual misuse. More practically, prompts that encode your brand's tone and vocabulary produce output editors actually use rather than generic results.
  • Treat AI output as an unverified draft - An editor who accepts AI output without checking it can publish incorrect information. The editorial response is to treat AI as a first-draft contribution: review before publishing, fact-check claims, and train editors accordingly.

What does running AI in CKEditor cost?

For a team of ten editors doing five AI-assisted edits per day, monthly API costs at Anthropic's Haiku 4.5 pricing ($1 per million input tokens, $5 per million output tokens) run under $20. Claude Sonnet 4.6 - better quality for complex rewrites - runs $3 per million input tokens and $15 per million output tokens. A typical editorial AI request uses 500 to 800 tokens.

The number that surprises teams is not the per-request cost. It is the bill at the end of the month when usage has quietly grown, and no budget alerts were configured. Set alerts in your provider console before you roll out to a wider team.

Ollama eliminates API costs. The cost shifts to compute and model maintenance.

When does a custom plugin make sense?

The default actions cover general editorial tasks: rewrite, translate, summarize, fix spelling. Organization-specific needs tend to surface a few weeks into real usage, once editors stop experimenting and start working.

A government team wants a plain-language action that rewrites to a defined readability standard. A marketing team wants a summarize-for-social action formatted for one platform. A legal team wants a standard disclaimer insert that editors can drop in without retyping.

These are custom AI plugins. Building one takes familiarity with CKEditor plugin registration and the AI module's plugin API, plus a precise definition of the editorial task. The second part is the harder one; a vague prompt produces a vague plugin.

Internal linking shows where custom tooling earns its keep. Useful link suggestions require awareness of the content already on your site, something a generic rewrite prompt has no access to. SmartLinker AI, a module Specbee built for Drupal CKEditor, works this way: it surfaces internal link suggestions as editors write, based on your existing Drupal content.

Final thoughts

An AI assistant in CKEditor is straightforward to install. The decisions that make the rollout defensible - provider choice, data routing, access controls, logging, workflow enforcement - need to happen before the install. AI accelerates the draft. Humans govern the publishing.

The "Generate with AI" modal showing an editor prompt and the AI-generated response.

If you are evaluating how AI fits into your Drupal editorial workflow, talk to the team.

References

* https://www.drupal.org/project/ai

Frequently Asked Questions

Is AI CKEditor free?

Yes. The AI CKEditor submodule carries no licence cost. You pay for the LLM provider API you connect to. Running Ollama locally has no API cost.

Does my content get sent to OpenAI?

If OpenAI is your configured provider, yes - from your Drupal server, not the editor's browser. Your OpenAI API agreement governs how that data is handled, which is different from consumer ChatGPT terms.

Can I run this without sending data to a third party?

Yes, via Ollama and the ai_provider_ollama module. Open-source models run entirely on your own infrastructure. Quality is lower than commercial APIs for complex tasks; for standard editorial actions, it is usable.

Can editors publish AI content directly?

Only if your content moderation workflow allows self-publishing. The AI module adds no publishing controls of its own.

How do I control which editors see AI actions?

AI actions are configured per text format. Assign formats to roles deliberately and restrict them to the roles you want to have access.

What does the AI cost to run?

Enable the AI Logging submodule and monitor token usage in your provider console. Without logging, you are estimating; with it, you have data.

What if the AI returns wrong information?

It will, eventually. Treat every AI output as an unverified draft and enforce editorial review before publishing.

What is the difference between AI CKEditor and CKEditor AI?

AI CKEditor is free, runs on your server, and works with any supported provider, including self-hosted Ollama. CKEditor AI requires a commercial CKEditor licence and routes requests through CKSource's managed backend.

Contact us

LET'S DISCUSS YOUR IDEAS. 
WE'D LOVE TO HEAR FROM YOU.

CONTACT US SUBMIT RFP