A browser extension that adds a sidebar to DevTools for converting selected HTML elements to Markdown. Supports Chrome, Edge, and Firefox.
- Select any element in the Elements inspector and instantly see its Markdown conversion
- Live preview of the rendered Markdown
- Copy to clipboard or download as
.mdfile - Strips scripts, styles, and unnecessary attributes automatically
Coming soon - Chrome Web Store | Firefox Add-ons | Edge Add-ons
- Node.js 20+
- npm
git clone https://github.com/auy/HTML2MD.git
cd html2md
npm installnpm run build # Production build (Chrome/Edge)
npm run build:firefox # Production build (Firefox)npm run start:chrome # Chrome (auto-downloads Chrome for Testing)
npm run start:edge # Microsoft Edge
npm run start:firefox # Mozilla FirefoxOpen DevTools (F12) > Elements tab > look for the HTML2MD sidebar tab.
npm run dev # Watch mode (rebuilds on file changes)
npm run lint # Validate extension with web-ext lint
npm run package # Zip dist/ for store submissionWorks on Windows, macOS, Linux, and WSL. Platform detection is automatic.
- Cleaning - Strips
<script>,<style>,<noscript>tags and non-essential attributes - Conversion - Turndown converts HTML to Markdown (ATX headings, fenced code blocks, GFM strikethrough)
- Preview - marked renders the Markdown back to HTML for preview
- Fork the repository
- Create a feature branch (
git checkout -b feature/my-feature) - Commit your changes
- Push to the branch and open a Pull Request