DEV Community

Cover image for mdts – A Simple CLI Tool to Browse Local Markdown Files in a Web UI
Yuji Ueki
Yuji Ueki

Posted on

mdts – A Simple CLI Tool to Browse Local Markdown Files in a Web UI

Have you ever wanted to browse your local Markdown files like a wiki – instantly, with no setup or configuration?

That's why I created mdts (Markdown Tree Server) – a command-line tool that lets you serve any folder of Markdown files in your browser, complete with a navigable file tree and clean Markdown preview.

screenshot


🔧 What is mdts?

mdts is a lightweight CLI tool that runs a local web server for browsing Markdown files in a directory. It’s designed for:

  • Local note-taking and journaling
  • Previewing documentation before publishing
  • Exploring markdown-based project folders
  • Building a local personal wiki

🛠️ Features

  • 📁 Web-based tree navigation of your file system
  • 📄 Clean Markdown rendering, styled for readability
  • No config, no setup – just run one command
  • 🌐 Offline-first – works entirely on your local machine
  • 🧩 Single binary (via NPM) – no dependency hell

🚀 Usage

In any directory you want to preview,

npx mdts
Enter fullscreen mode Exit fullscreen mode

It will launch your default browser automatically, showing a tree of Markdown files and folders that you can browse and read.


🧪 Under the Hood

  • Built with Node.js
  • Uses Express.js for the server
  • Markdown rendering via React Markdown + custom styling

No frontend framework – just HTML/CSS/JS and a bit of magic ✨


🔓 Open Source

GitHub:
👉 https://github.com/unhappychoice/mdts

The project is fully open source and open to contributions.
If you find it useful or want to see new features (like search or edit mode), I’d love your feedback!


If this sounds useful to you, feel free to give it a ⭐ on GitHub and share it with others who work with Markdown.

Thanks for reading! 🙌

Top comments (0)