Online Markdown Editor & Live Preview

Write documentation, GitHub READMEs, and clean notes with a fast, distraction-free Markdown editor: desktop split-pane preview with scroll sync, mobile tab switcher, formatting toolbar, strict XSS-safe GFM rendering, local auto-save, and instant .md / .html export.

⚡ Quick Answer

DayToolHub Markdown Editor runs 100% locally in your browser with GitHub Flavored Markdown support (headings, emphasis, strikethrough, code blocks, tables, task lists, links & images), strict XSS sanitization blocking raw scripts and javascript:/data: URLs, automatic localStorage drafts, and one-click .md / standalone .html export.

How to Use Markdown Editor

  1. Type Markdown in the editor or use the formatting toolbar to insert headings, bold/italic text, checklists, code blocks, links, and tables.
  2. Switch between Split View, Editor Only, or Preview Only on desktop (with synchronized scrolling), or flip between Edit and Preview tabs on mobile.
  3. Track live character count, word count, line count, and estimated reading time while your draft saves automatically to localStorage.
  4. Use Copy HTML, Export .md, or Export Standalone .html whenever your document is ready.

GitHub Flavored Markdown (GFM) Quick Cheat Sheet

Element Markdown Syntax Notes
Headings# H1 / ## H2 / ### H3Leave one space after the hashes
Emphasis**bold**, *italic*, ~~strike~~Can be combined inline
Task Lists- [x] Done / - [ ] TodoRenders clean checklist items
Code BlocksTriple backticks ```js ... ```Preserves indentation and escapes brackets
TablesPipe-delimited rows with --- separatorSupports left, center, and right alignment
Links & Images[Label](https://...) / ![Alt](https://...)External links include safe rel attributes

Why XSS-Safe Markdown Rendering Matters

Many web previewers inject raw HTML straight into the page, allowing pasted <script> tags, onerror handlers, or javascript: links to execute unintended code. DayToolHub escapes all raw HTML and enforces a strict URL allowlist (https:, http:, mailto:, and relative paths) so previewing untrusted Markdown stays completely safe.

Frequently Asked Questions (FAQ)

Will I lose my writing if I refresh or close the tab?
No. Your draft is automatically saved in your browser localStorage as you type and restored when you return, unless you clear browser site data.
Does it support GFM tables and checkbox task lists?
Yes. Standard pipe tables with column alignment and - [ ] / - [x] task lists are rendered live, and the toolbar can insert ready-to-edit templates in one click.
Is it safe to paste untrusted Markdown containing HTML or scripts?
Yes. The built-in parser escapes raw HTML tags such as <script>, <iframe>, and <img onerror=...> as literal text and blocks javascript:, vbscript:, and data: URLs.
What is the difference between "Copy HTML" and "Export .html"?
"Copy HTML" copies only the rendered HTML fragment for pasting into a CMS or blog editor, while "Export .html" downloads a complete standalone HTML5 webpage with clean typography ready to open offline or print to PDF.
How does the layout work on mobile devices?
On smaller screens, the split view switches cleanly into Edit and Preview tabs so you always have full screen width for comfortable typing and reading.

Related Tools & Further Reading