JavaScript Markdown editor libraries

Updated Nov 2026

JavaScript Markdown editor libraries embed a Markdown writing surface in a web page. An editor either shows the Markdown source beside a rendered preview or hides the syntax behind formatted text. These libraries let documentation tools, issue trackers, and note-taking apps store user writing as portable plain text.

Popularity

Lexical + Markdown has the most monthly downloads in this comparison, at 31.2M.

LibraryMonthly downloadsStarsLast releaseLicense
@lexical/markdown
31.2M
24.0KOct 2026MIT
@tiptap/markdown
25.3M
39.1KNov 2026MIT
MDXEditor
7.7M
3.7KNov 2026MIT
@uiw/react-md-editor
4.2M
2.9KNov 2026MIT
Milkdown
3.5M
12.1KOct 2026MIT
EasyMDE
1.2M
3.1KMay 2026MIT
TOAST UI Editor
1.2M
18.0KNov 2026MIT
react-markdown-editor-lite
270.7K
1.1KJan 2026MIT
Downloads: npm, last thirty days. Stars and releases: GitHub. Amber: no release in over a year.

Libraries and code examples

@lexical/markdown

Adds Markdown helpers and functionality to the Lexical editor.

Downloads / mo
31.2M
Stars
24.0K
Last release
0.53.0
License
MIT

Quickstart

From lexical-markdown
$ npm install lexical@0.53.0 @lexical/rich-text@0.53.0 @lexical/markdown@0.53.0
import { createEditor } from "lexical";
import { registerRichText } from "@lexical/rich-text";
import { BOLD_STAR, ITALIC_STAR, registerMarkdownShortcuts, $convertFromMarkdownString } from "@lexical/markdown";

const root = document.createElement("div");
root.contentEditable = "true";
document.body.append(root);
const editor = createEditor({ namespace: "markdown", onError(error) { throw error; } });
editor.setRootElement(root);
registerRichText(editor);
const transformers = [BOLD_STAR, ITALIC_STAR];
registerMarkdownShortcuts(editor, transformers);
editor.update(() => $convertFromMarkdownString("**Hello**", transformers));

@lexical/markdown examples

From open-source projects on GitHub

@tiptap/markdown

Parses and serializes Markdown for the Tiptap editor.

Downloads / mo
25.3M
Stars
39.1K
Last release
3.34.0
License
MIT

Quickstart

From basic-usage
$ npm install @tiptap/core@3.34.0 @tiptap/pm@3.34.0 @tiptap/starter-kit@3.34.0 @tiptap/markdown@3.34.0
import { Editor } from "@tiptap/core";
import StarterKit from "@tiptap/starter-kit";
import { Markdown } from "@tiptap/markdown";

const element = document.createElement("div");
document.body.append(element);
const editor = new Editor({
  element, extensions: [StarterKit, Markdown],
  content: "# Hello **Markdown**", contentType: "markdown",
});
console.log(editor.getMarkdown());

@tiptap/markdown examples

From open-source projects on GitHub

Provides a React component for rich-text Markdown editing.

Downloads / mo
7.7M
Stars
3.7K
Last release
4.5.0
License
MIT

Quickstart

From getting-started
$ npm install react@18.3.1 react-dom@18.3.1 @mdxeditor/editor@4.5.0
import { MDXEditor } from "@mdxeditor/editor";
import "@mdxeditor/editor/style.css";

export default function App() {
  return <MDXEditor markdown="Hello, world." />;
}

MDXEditor examples

From open-source projects on GitHub

@uiw/react-md-editor

Edits Markdown with a live preview, built with React and TypeScript.

Downloads / mo
4.2M
Stars
2.9K
Last release
4.2.4
License
MIT

Quickstart

From react-md-editor
$ npm install react@18.3.1 react-dom@18.3.1 @uiw/react-md-editor@4.2.4
import { useState } from "react";
import MDEditor from "@uiw/react-md-editor";
import "@uiw/react-md-editor/markdown-editor.css";

export default function App() {
  const [value, setValue] = useState("**Hello**");
  return <MDEditor value={value} onChange={(nextValue) => setValue(nextValue ?? "")} />;
}

Provides a plugin-driven WYSIWYG Markdown editor framework.

Downloads / mo
3.5M
Stars
12.1K
Last release
7.23.0
License
MIT

Quickstart

From getting-started
$ npm install @milkdown/core@7.23.0 @milkdown/preset-commonmark@7.23.0
import { Editor, rootCtx, defaultValueCtx } from "@milkdown/core";
import { commonmark } from "@milkdown/preset-commonmark";

const root = document.createElement("div");
document.body.append(root);
await Editor.make()
  .config((ctx) => {
    ctx.set(rootCtx, root);
    ctx.set(defaultValueCtx, "# Hello");
  })
  .use(commonmark)
  .create();

Milkdown examples

From open-source projects on GitHub

Replaces a textarea with a customizable Markdown editor.

Downloads / mo
1.2M
Stars
3.1K
Last release
2.21.0
License
MIT

Strengths

  • Autosaves drafts locally. Enable autosave to restore unfinished document text.
  • Customizes toolbar controls. Choose built-in buttons or define custom actions.

Limitations

  • Code highlighting needs another library. Load highlight.js or pass an instance for rendered code highlighting.
  • Autosave IDs must be unique. Give every editor instance its own autosave identifier.

Quickstart

From README.md
$ npm install easymde@2.21.0
import EasyMDE from "easymde";
import "easymde/dist/easymde.min.css";

const textarea = document.createElement("textarea");
document.body.append(textarea);
const editor = new EasyMDE({ element: textarea, initialValue: "# Hello" });
console.log(editor.value());

EasyMDE examples

From open-source projects on GitHub

TOAST UI Editor

Provides switchable Markdown and visual editing modes.

Downloads / mo
1.2M
Stars
18.0K
Last release
3.2.3
License
MIT

Strengths

  • Switches between editing modes. Move between Markdown source and visual editing in one editor.
  • Edits tables through context menus. Add or remove table rows and columns without editing Markdown separators.

Limitations

  • Highlighted code needs a plugin. Install and register the code-syntax-highlight plugin for rendered code blocks.
  • Hostname reporting needs configuration. Set usageStatistics to false when hostname reporting must be disabled.

Quickstart

From getting-started.md
$ npm install @toast-ui/editor@3.2.3
import Editor from "@toast-ui/editor";
import "@toast-ui/editor/dist/toastui-editor.css";

const el = document.createElement("div");
document.body.append(el);
const editor = new Editor({
  el, height: "400px", initialEditType: "markdown",
  previewStyle: "vertical", initialValue: "# Hello", usageStatistics: false,
});
console.log(editor.getMarkdown());

TOAST UI Editor examples

From open-source projects on GitHub

react-markdown-editor-lite

Provides a Markdown editor component for React.

Downloads / mo
270.7K
Stars
1.1K
Last release
1.4.2
License
MIT

Quickstart

From README.md
$ npm install react@18.3.1 react-dom@18.3.1 react-markdown-editor-lite@1.4.2 markdown-it@14.1.0
import { useState } from "react";
import MdEditor from "react-markdown-editor-lite";
import MarkdownIt from "markdown-it";
import "react-markdown-editor-lite/lib/index.css";

const parser = new MarkdownIt();
export default function App() {
  const [value, setValue] = useState("# Hello");
  return <MdEditor value={value} renderHTML={(text) => parser.render(text)}
    onChange={({ text }) => setValue(text)} style={{ height: 360 }} />;
}

react-markdown-editor-lite examples

From open-source projects on GitHub

FAQ

EasyMDE suits pages that replace a textarea without a framework. MDXEditor suits React apps that want a ready visual Markdown editor. Tiptap + Markdown suits apps that build their own editor and need Markdown import and export.

MDXEditor is a ready React rich-text Markdown editor with an opt-in toolbar. UIW React MD Editor edits Markdown source in a textarea with a rendered preview.

Tiptap + Markdown adds official Markdown parsing and serialization to the Tiptap editor. The app still configures the schema, extensions, and UI.

A WYSIWYG Markdown editor shows formatted text while it writes Markdown underneath. Milkdown and TOAST UI Editor offer this visual mode.

Both are low-level editor frameworks that leave nodes and UI to the app. Lexical + Markdown adds import, export, and Markdown shortcuts to Lexical. Tiptap + Markdown adds Markdown content commands to Tiptap.

For coding agents

Found your Markdown editor library? Help your agent use it.

Connect Exa so your coding agent can find the library’s documentation, check its API, and look up implementations while you build.

Run in your terminal

claude plugin install exa@claude-plugins-official