mdtab
Open a Markdown file from Finder and it appears in a browser tab: the folder tree on the left, the rendered document on the right. White background, no Electron, no accounts.
- Double-click a
.mdin Finder (aftermdtab install --default) or runmdtab open file.md - Left pane: the folder that contains the file. Expand subfolders, go up with
↑, click any.md - Live reload: the document re-renders when the file changes on disk
- Images and attachments resolve relative to the Markdown file
- Links to local
.mdfiles navigate in the same tab; external URLs open in a new tab - "Reveal in Finder" button
Install
brew install pandoc # renderer (GitHub-flavored Markdown)
uv tool install mdtab # or: pipx install mdtab / pip install mdtab
mdtab install --default # macOS: launchd agent + MDTab.app, make it the default .md app
macOS asks once to confirm the default-app change. Then:
open README.md # Finder double-click does the same
mdtab open README.md # works without the default-app setup
No pandoc? uv tool install "mdtab[markdown]" installs python-markdown as a fallback renderer (nested lists need 4-space indents there).
Commands
| Command | What it does |
|---|---|
mdtab open [file.md] |
Start the server if needed and open the file in your default browser |
mdtab serve [--port N] |
Run the server in the foreground (this is what launchd runs) |
mdtab install [--default] |
macOS: write the launchd agent, build ~/Applications/MDTab.app, register it for Markdown; --default makes it the default handler |
mdtab uninstall |
Remove the agent and the app |
serve and open work on any OS; install/uninstall are macOS only.
How it works
| Piece | Role |
|---|---|
mdtab/server.py |
HTTP server on 127.0.0.1:7331. Routes: /view, /api/tree, /api/file, /api/raw, /api/mtime, /api/reveal |
mdtab/static/ |
Single-page UI |
mdtab/cli.py |
mdtab command |
mdtab/macos.py |
launchd plist, AppleScript droplet compiled with osacompile, LaunchServices registration |
The launchd agent runs <the python mdtab was installed with> -m mdtab serve, so it follows whatever uv/pipx/venv you installed into.
Security notes
- Binds to
127.0.0.1only. - Serves only paths under
$HOME; anything else returnsbad file. - Raw HTML in Markdown is rendered (so
<img width=...>works). This is a viewer for your own local files; do not expose it to a network.
Development
git clone https://github.com/Tdual/mdtab.git && cd mdtab
uv tool install --force ".[markdown]" # or: pip install -e ".[markdown]"
python -m unittest discover -s tests -v
mdtab open test/index.md # images, links, a folder with a space in its name
Releases are published to PyPI by the Publish to PyPI workflow when a v* tag is pushed (Trusted Publishing).
License
MIT
Metadata
Release files for mdtab 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| mdtab-0.1.0.tar.gz | 136.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| mdtab-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 149.7 kB
Release files / mdtab-0.1.0.tar.gz
| Download URL | mdtab-0.1.0.tar.gz |
|---|---|
| Size | 136.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d9716644619ae2db5baa5a6d373e5c5d880940921252f9157313ae09092e54eb
|
|
BLAKE2b-256 checksum How to use checksums |
cae09d4fb071d49e792ed7a116e227f6007d9cdd73efec50a29a7eabacb43c9a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 2, 2026.
Transparency logRelease files / mdtab-0.1.0-py3-none-any.whl
| Download URL | mdtab-0.1.0-py3-none-any.whl |
|---|---|
| Size | 13.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
784f60cb8b898f9e5111c239fc92821f247548ac81575fd36c456292cb96c4b1
|
|
BLAKE2b-256 checksum How to use checksums |
02913ee323464c984832836efe9aee5eeab1b23064a653a8f3805c54ed7a58d6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 2, 2026.
Transparency log