Markdown to Something
With support for Mermaid diagrams and LaTeX equations
Paste your Markdown below and choose an export option.
Advanced Features
- Mermaid Diagrams - Create flowcharts, sequence diagrams, and more using
```mermaidcode blocks - LaTeX Equations - Render mathematical expressions using
$...$for inline and$$...$$for display equations - Syntax Highlighting - Code blocks are automatically highlighted
API Usage
You can also use our API to convert markdown programmatically. Here are some examples using cURL:
Convert to DOCX
curl -X POST -H "Content-Type: application/json" \
-d '{"markdown": "# Hello World"}' \
https://md.colinknapp.com/api/convert
Convert to HTML (Professional Template)
curl -X POST -H "Content-Type: application/json" \
-d '{"markdown": "# Hello World", "format": "html", "template": "professional",
"title": "Document Title", "subtitle": "Document Subtitle",
"contact": "Contact Information", "footer": "Footer Text"}' \
https://md.colinknapp.com/api/convert
Convert to HTML and Send to Haste
curl -X POST -H "Content-Type: application/json" \
-d '{"markdown": "# Hello World", "format": "html", "template": "professional",
"send_to_haste": true}' \
https://md.colinknapp.com/api/convert
When using send_to_haste: true, the response will include haste_key, haste_url, and preview_url fields.
Mermaid diagrams and MathJax/LaTeX are both supported per template. Each template has default settings (e.g. monospace and hacker disable MathJax by default). When your content contains diagrams or equations, the appropriate scripts are injected automatically.
MCP (Model Context Protocol) Integration
This service is available as an MCP server, allowing you to use markdown conversion capabilities directly from MCP-compatible clients like Cursor, Claude Desktop, and other AI assistants. Discovery aligns with MCP Discovery via Well-Known URI.
Server Card Endpoint
The MCP server card is available at:
https://md.colinknapp.com/.well-known/mcp/server-card.json
This endpoint provides metadata about the service, including available tools, capabilities, and transport configuration.
Adding to Cursor
To add this service to Cursor, edit your MCP configuration file (typically ~/.cursor/mcp.json or .cursor/mcp.json in your project):
{
"mcpServers": {
"markdown-to-something": {
"url": "https://md.colinknapp.com"
}
}
}
Note: The server card endpoint (/.well-known/mcp/server-card.json) provides the transport configuration. If your MCP client supports server card discovery, it will automatically use the transport details from the server card.
Adding to Claude Desktop
To add this service to Claude Desktop, edit your MCP configuration file:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%/Claude/claude_desktop_config.json
{
"mcpServers": {
"markdown-to-something": {
"url": "https://md.colinknapp.com"
}
}
}
If your Claude Desktop version requires using mcp-remote, you can use:
{
"mcpServers": {
"markdown-to-something": {
"command": "npx",
"args": ["-y", "mcp-remote", "https://md.colinknapp.com"]
}
}
}
Available MCP Tools
The service provides the following MCP tool:
- convert_markdown: Convert Markdown content to HTML, DOCX, or PDF format with various template options
Tool Parameters
markdown(required): The Markdown content to converttemplate(optional): Template name (e.g., 'minimalist-light', 'professional', 'academic'). Default: 'minimalist-light'output_format(optional): Output format - 'html', 'docx', or 'pdf'. Default: 'html'title(optional): Document titlesubtitle(optional): Document subtitlecontact(optional): Contact informationfooter(optional): Footer text
Example Usage
Once configured, you can use the service from your MCP client:
# In Cursor or Claude Desktop, you can now ask:
"Convert this markdown to HTML using the professional template:
# My Document
This is my content."
# The AI assistant will use the MCP tool to convert your markdown
# and return the formatted HTML.
Verifying the Setup
You can verify the MCP server card is accessible by visiting:
curl https://md.colinknapp.com/.well-known/mcp/server-card.json
This should return a JSON document describing the service capabilities. A short markdown summary is also available at /.well-known/skills.md. For the discovery specification, see MCP Discovery via Well-Known URI.
Template Configuration (Mermaid & MathJax)
Mermaid and MathJax work together. Each template has default settings; when your content contains diagrams or LaTeX, the appropriate scripts are injected automatically. There are no user-facing feature flags.
WCAG-Compliant Templates
All WCAG-compliant templates support both Mermaid and MathJax:
- professional, classic, modern, creative
- academic, blog, corporate, newspaper
- minimalist-light, playful, modern-photo, compact
Template Defaults
Some templates disable MathJax by default (e.g. monospace, hacker, slides-monospace). Template defaults are defined in template_config.py.
Advanced Features
Using Mermaid Diagrams
Include Mermaid diagrams in your markdown using code blocks with the mermaid language identifier:
```mermaid
graph TD
A[Start] --> B{Is it raining?}
B -->|Yes| C[Take umbrella]
B -->|No| D[Enjoy the weather]
```
Using LaTeX Equations
Include mathematical expressions using LaTeX syntax:
- Inline equations: Use single dollar signs
$E = mc^2$ - Display equations: Use double dollar signs
$$ \frac{d}{dx}[x^n] = nx^{n-1} $$
Note: For currency symbols in text, escape the dollar sign with a backslash: \$5.99
Template Feature Configuration
Each template declares whether it supports Mermaid and MathJax in template_config.py. Both are injected when the template allows and the content contains diagrams or equations.
Quick Reference
| Template Category | Mermaid | MathJax |
|---|---|---|
| WCAG Templates (12) | ✅ Enabled | ✅ Enabled |
| monospace, hacker | ✅ Enabled | ❌ Disabled |
| glitch | ❌ Disabled | ❌ Disabled |
| Most Slide Templates | ✅ Enabled | ✅ Enabled |
Testing & Verification
All templates are tested to ensure feature flags work correctly:
- ✅ Template defaults are respected when flags not provided
- ✅ Feature flags override template defaults
- ✅ Script injection matches flag settings
- ✅ WCAG templates behave consistently
For Developers: See FEATURE_FLAGS_CONSISTENCY_PLAN.md for the complete testing and implementation plan.
Haste Integration
This application integrates with haste.nixc.us to allow sharing HTML output without requiring server-side storage:
- HTML Sharing: Convert markdown to HTML and share via a unique URL
- Preview Endpoint: View shared HTML documents through the application's preview endpoint
To use this feature, check the "Send HTML to haste.nixc.us" option before converting.
The preview URL format is: https://md.colinknapp.com/haste/{haste_key}
Template Feature Configuration
Each template declares whether it supports Mermaid and MathJax in template_config.py. Both are injected when the template allows and the content contains diagrams or equations.
Quick Reference
| Template Category | Mermaid | MathJax |
|---|---|---|
| WCAG Templates (12) | ✅ Enabled | ✅ Enabled |
| monospace, hacker | ✅ Enabled | ❌ Disabled |
| glitch | ❌ Disabled | ❌ Disabled |
| Most Slide Templates | ✅ Enabled | ✅ Enabled |
Testing & Verification
All templates are tested to ensure feature flags work correctly:
- ✅ Template defaults are respected when flags not provided
- ✅ Feature flags override template defaults
- ✅ Script injection matches flag settings
- ✅ WCAG templates behave consistently
For Developers: See FEATURE_FLAGS_CONSISTENCY_PLAN.md for the complete testing and implementation plan.