{"uid":"cap_ZcIfX1tH8BCObQ89ejidZ","slug":"markdown-to-html-converter-95b76f92","name":"Markdown to HTML Converter","description":"Render Markdown to HTML — CommonMark with autolinking; raw HTML in the input is escaped, not executed. The inverse of /html/to-markdown.","url":"https://toolbelt402.tpoborne.workers.dev/markdown/to-html","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"markdown":{"type":"string","description":"CommonMark text (max 256 KB); raw HTML is escaped, not executed"}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.003","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.003/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.003","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.003","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_ptDSXfuiVaq5S8mIWE8We","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.003","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Renders Markdown text to HTML using CommonMark spec with autolinking, safely escaping any raw HTML in the input rather than executing it.","exampleAgentPrompt":"Convert this Markdown to HTML for me: '# Hello World\\n\\nThis is a **bold** statement with a link https://example.com — make sure any raw HTML tags in the input are escaped, not rendered.'","exampleUseCases":[{"title":"Render README for web display","prompt":"I have a GitHub README in Markdown and I need to display it as HTML on a webpage — convert it for me, and make sure any raw HTML tags in the markdown get escaped so they can't execute."},{"title":"Blog post Markdown to HTML pipeline","prompt":"Take this blog post I wrote in Markdown and convert it to HTML so I can save it to the database and render it in the browser: '## My Post\\n\\nHere is a paragraph with **bold** and _italic_ text and a link to https://myblog.com.'"},{"title":"Safely render user-submitted Markdown","prompt":"A user submitted this Markdown comment and I need to render it as HTML for display — make sure any raw HTML they snuck in gets escaped: '## Comment\\n\\nGreat post! <script>alert(1)</script> Check this out https://example.com'"}],"resultDescription":"Returns an HTML string converted from the input Markdown. The output is CommonMark-compliant, with URLs autolinked and any raw HTML tags in the source escaped (converted to their HTML entity equivalents like &lt;script&gt;) rather than passed through, preventing XSS injection.","failureModes":["Empty or missing input body returns a 400 error","Extremely large Markdown documents may time out or be rejected","Non-UTF-8 encoded input may cause parsing errors","Payment failure (x402) blocks the request before processing"],"whenToPreferThis":"Choose this endpoint when you need a lightweight, safe, server-side Markdown-to-HTML conversion that strictly follows CommonMark and automatically escapes raw HTML (preventing XSS). Prefer it over client-side renderers when security matters, and over full document processors when you only need the HTML fragment, not a full page. It is the natural inverse of the /html/to-markdown sibling endpoint on the same toolbelt.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T12:48:02.224Z","isFirstParty":false}