Adds an HTML editor field to Payload 3 that stores content as an HTML string instead of editor-specific JSON. It registers through a plugin that sets a default upload collection, and a field helper that you place in collections or globals. Tiptap packages are peer dependencies, and the admin import map must be regenerated after adding the field. The package does not sanitize HTML for public display.
A Payload CMS 3 WYSIWYG field for editing HTML with Tiptap, rich-text tools, tables, and media.
Installation
npm i payload-html-editor0
Stars
0
Forks
0
Open Issues
5 days ago
Last Updated
222
Weekly Downloads
v0.1.6
npm Version
72.2 KB
Unpacked Size
0
Dependencies
00 since Oct 4
| Date | Stars |
|---|---|
| Dec 5, 2026 | 0 |
| Dec 4, 2026 | 0 |
| Dec 3, 2026 | 0 |
| Dec 2, 2026 | 0 |
| Dec 1, 2026 | 0 |
| Nov 30, 2026 | 0 |
| Nov 29, 2026 | 0 |
| Nov 28, 2026 | 0 |
| Nov 27, 2026 | 0 |
| Nov 26, 2026 | 0 |
| Nov 25, 2026 | 0 |
| Nov 24, 2026 | 0 |
| Nov 23, 2026 | 0 |
| Nov 22, 2026 | 0 |
| Nov 21, 2026 | 0 |
| Nov 20, 2026 | 0 |
| Nov 19, 2026 | 0 |
| Nov 18, 2026 | 0 |
| Nov 17, 2026 | 0 |
| Nov 16, 2026 | 0 |
| Nov 15, 2026 | 0 |
| Nov 14, 2026 | 0 |
| Nov 13, 2026 | 0 |
| Nov 12, 2026 | 0 |
| Nov 11, 2026 | 0 |
| Nov 10, 2026 | 0 |
| Nov 9, 2026 | 0 |
| Nov 8, 2026 | 0 |
| Nov 7, 2026 | 0 |
| Nov 6, 2026 | 0 |
| Nov 5, 2026 | 0 |
| Nov 4, 2026 | 0 |
| Nov 3, 2026 | 0 |
| Nov 2, 2026 | 0 |
| Nov 1, 2026 | 0 |
| Oct 31, 2026 | 0 |
| Oct 30, 2026 | 0 |
| Oct 29, 2026 | 0 |
| Oct 28, 2026 | 0 |
| Oct 27, 2026 | 0 |
| Oct 26, 2026 | 0 |
| Oct 25, 2026 | 0 |
| Oct 24, 2026 | 0 |
| Oct 23, 2026 | 0 |
| Oct 22, 2026 | 0 |
| Oct 21, 2026 | 0 |
| Oct 20, 2026 | 0 |
| Oct 19, 2026 | 0 |
| Oct 18, 2026 | 0 |
| Oct 17, 2026 | 0 |
| Oct 16, 2026 | 0 |
| Oct 15, 2026 | 0 |
| Oct 14, 2026 | 0 |
| Oct 13, 2026 | 0 |
| Oct 12, 2026 | 0 |
| Oct 11, 2026 | 0 |
| Oct 10, 2026 | 0 |
| Oct 9, 2026 | 0 |
| Oct 8, 2026 | 0 |
| Oct 7, 2026 | 0 |
| Oct 6, 2026 | 0 |
| Oct 5, 2026 | 0 |
| Oct 4, 2026 | 0 |
212−245 since Oct 12
| Date | Weekly downloads |
|---|---|
| Dec 5, 2026 | 212 |
| Dec 4, 2026 | 197 |
| Dec 3, 2026 | 195 |
| Dec 2, 2026 | 38 |
| Dec 1, 2026 | 44 |
| Nov 30, 2026 | 69 |
| Nov 29, 2026 | 156 |
| Nov 28, 2026 | 155 |
| Nov 27, 2026 | 156 |
| Nov 26, 2026 | 153 |
| Nov 25, 2026 | 142 |
| Nov 24, 2026 | 135 |
| Nov 23, 2026 | 105 |
| Nov 22, 2026 | 7 |
| Nov 21, 2026 | 8 |
| Nov 20, 2026 | 16 |
| Nov 19, 2026 | 17 |
| Nov 18, 2026 | 21 |
| Nov 17, 2026 | 27 |
| Nov 16, 2026 | 31 |
| Nov 15, 2026 | 33 |
| Nov 14, 2026 | 33 |
| Nov 13, 2026 | 27 |
| Nov 12, 2026 | 33 |
| Nov 11, 2026 | 30 |
| Nov 10, 2026 | 24 |
| Nov 9, 2026 | 20 |
| Nov 8, 2026 | 19 |
| Nov 7, 2026 | 27 |
| Nov 6, 2026 | 23 |
| Nov 5, 2026 | 17 |
| Nov 4, 2026 | 14 |
| Nov 3, 2026 | 18 |
| Nov 2, 2026 | 23 |
| Nov 1, 2026 | 22 |
| Oct 31, 2026 | 13 |
| Oct 30, 2026 | 15 |
| Oct 29, 2026 | 14 |
| Oct 28, 2026 | 14 |
| Oct 27, 2026 | 19 |
| Oct 26, 2026 | 22 |
| Oct 25, 2026 | 34 |
| Oct 24, 2026 | 44 |
| Oct 23, 2026 | 41 |
| Oct 22, 2026 | 85 |
| Oct 21, 2026 | 387 |
| Oct 20, 2026 | 414 |
| Oct 19, 2026 | 440 |
| Oct 18, 2026 | 883 |
| Oct 17, 2026 | 873 |
| Oct 16, 2026 | 873 |
| Oct 15, 2026 | 829 |
| Oct 14, 2026 | 527 |
| Oct 13, 2026 | 491 |
| Oct 12, 2026 | 457 |
Each point is npm's rolling 7-day download count.
Health Score
Composite score based on GitHub activity, stars, npm downloads, publish recency, dependency count, and package size.
Badge for your README
[](https://payloaddirectory.dev/plugins/1411796536-root)<a href="https://payloaddirectory.dev/plugins/1411796536-root"><img src="https://payloaddirectory.dev/badge/1411796536-root.svg" alt="Payload Directory"></a>README
A visual HTML editor field for Payload CMS 3, powered by Tiptap.
Give content editors a familiar toolbar-based WYSIWYG workflow, similar in spirit to the classic WordPress editor or CKEditor, while saving content as an HTML string—not editor-specific JSON. It’s a good fit for projects that need to work with existing HTML, render content on the frontend, or integrate with HTML-based systems.
This is an independent editor, not a WordPress or CKEditor clone, and is not affiliated with either project.
textarea field and Payload's admin field component system.npm install payload-html-editor
This package uses Payload, React, and Tiptap packages provided by your application. With npm 7 or later, npm installs peer dependencies automatically by default. If your project sets legacy-peer-deps=true in .npmrc, npm skips that automatic installation. Remove that setting or install the Tiptap packages explicitly:
npm install \
@tiptap/core@^3.31.4 \
@tiptap/extension-file-handler@^3.31.4 \
@tiptap/extension-image@^3.31.4 \
@tiptap/extension-table@^3.31.4 \
@tiptap/extension-text-align@^3.31.4 \
@tiptap/react@^3.31.4 \
@tiptap/starter-kit@^3.31.4
Payload, @payloadcms/ui, React, and React DOM are also declared as peer dependencies. A Payload application normally already has these installed.
The editor component imports its styles. If your application needs a direct CSS import, include this in your admin bundle:
import 'payload-html-editor/styles.css'
Add the plugin to your Payload config. Set mediaCollection to the slug of your Payload upload collection:
import { buildConfig } from 'payload'
import { htmlEditorPlugin } from 'payload-html-editor'
export default buildConfig({
plugins: [
htmlEditorPlugin({
mediaCollection: 'media',
}),
],
})
Use the field in a collection or global:
import type { CollectionConfig } from 'payload'
import { htmlEditorField } from 'payload-html-editor'
export const Pages: CollectionConfig = {
slug: 'pages',
fields: [
htmlEditorField({
name: 'content',
label: 'Content',
}),
],
}
Regenerate Payload's admin import map after adding or changing the field:
npx payload generate:importmap
All editor features are enabled by default. Disable individual features for a field:
htmlEditorField({
name: 'summary',
features: {
images: false,
tables: false,
sourceEditing: false,
textAlignment: true,
},
})
Enable Payload localization per field with localized: true:
htmlEditorField({
name: 'content',
localized: true,
})
Set localized: false (the default) to keep the value shared across locales.
The plugin's mediaCollection is the default for every editor field. A field can override it:
htmlEditorField({
name: 'content',
mediaCollection: 'assets',
maxUploadSize: 5 * 1024 * 1024,
})
| Option | Type | Default | Description |
|---|---|---|---|
name | string | Required | Payload field name |
label | string | Field name | Admin field label |
required | boolean | false | Whether the field is required |
localized | boolean | false | Whether the field has a separate value for each configured locale |
mediaCollection | string | Plugin setting or media | Upload collection used for image selection and upload |
maxUploadSize | number | 10 MB | Maximum image upload size in bytes |
features.images | boolean | true | Image insertion, upload, and media library |
features.tables | boolean | true | Table editing controls |
features.sourceEditing | boolean | true | HTML source modal |
features.textAlignment | boolean | true | Text alignment controls |
admin | TextareaField['admin'] | — | Additional Payload admin field configuration |
componentPath | string | payload-html-editor/client#HtmlEditor | Custom admin field component path |
Disabled features are omitted from both the toolbar and the Tiptap extension list.
Image upload and selection use Payload's REST API with the current admin user's credentials. Configure an upload collection and make sure its documents include:
idurlalt, filename, width, and heightsizes with url and width for responsive srcsetUploads are limited to JPEG, PNG, WebP, and GIF. Configure access on your collection as appropriate for your Payload users.
It offers a comparable toolbar-based visual editing workflow for common rich-text tasks, but it is not feature-for-feature compatible with CKEditor or WordPress. It is designed specifically as a Payload CMS field, and Tiptap's schema determines which HTML elements and attributes can be represented.
Existing HTML may be a useful starting point when migrating, but test representative content before switching. WordPress block-editor comments/blocks and markup or editor-specific CKEditor data may need conversion. Unsupported tags and attributes can be removed when Tiptap parses and saves content.
The source editor allows admins to enter HTML that Tiptap can parse through its configured schema. This package does not sanitize HTML for public display. Sanitize saved content at your application's output boundary according to your XSS policy, especially if content can be supplied by untrusted users.
The published package is developed and tested with:
3.90.x19.2.x3.31.x^18.20.2 || >=20.9.0Payload, React, and Tiptap are peer dependencies. Next.js is not required by the package itself, but is commonly used with Payload.
npm install
npm run build
npm run pack:check
npm run pack:check builds the package and previews the files that would be published. Before opening a release, test the packed package in a Payload application.
MIT
payload paste as markdown
Lexical editor feature for pasting raw Markdown through a toolbar button, slash command, or drawer
631.2k/wk0v3
payload richtext lexical react native
React Native renderer for serialized Lexical rich text content from Payload CMS
3918/wk0v3
payload plugin lexical
Lexical-based rich text editor field for Payload 1.x with tables, embeds, and a customizable feature set
35152/wk213v1
ox payload editorial
Editorial Lexical blocks written as markdown directives, with lossless round trip and token-styled rendering
250v3 v4
fullscreen editor
Fullscreen mode for the Lexical rich text editor in the Payload admin
88347/wk115v4
payload editor
Declarative presets and typed feature toggles for configuring the Payload Lexical rich-text editor
7225/wk3v3