Previewing README rendering before pushing
Table alignment, nested list indentation and fenced-code language hints are the three things that look right in an editor and wrong on the host. Rendering locally catches them before the commit.
Renders Markdown into sanitized HTML.
—Renders Markdown into sanitized HTML.
# Hi - one - two
<h1>Hi</h1> <ul><li>one</li><li>two</li></ul>
The output is sanitized to remove script and dangerous markup.
Sanitized means scripts and event handlers are stripped.
Your input is sent to YAS infrastructure because the tool requires server-side processing or public network queries. Input is not stored.
curl -X POST "https://yas.sh/api/v1/tools/markdown-to-html" \
-H "Content-Type: application/json" \
-d '{"input":"# Hello\n\n**bold**"}'const res = await fetch("https://yas.sh/api/v1/tools/markdown-to-html", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"input": "# Hello\n\n**bold**"
}),
});
const data = await res.json();import requests
r = requests.post("https://yas.sh/api/v1/tools/markdown-to-html", json={"input":"# Hello\n\n**bold**"})
data = r.json()| Field | Type | Required | Description |
|---|---|---|---|
| input | string | Yes | Markdown (≤ 64 KB) |
{ "result": "<h1>Hello</h1>\n<p><strong>bold</strong></p>" }Render Markdown to sanitized HTML (marked + sanitize-html allow-list, XSS-safe).
400 VALIDATION_ERROR — invalid input or unsupported option.413 PAYLOAD_TOO_LARGE — input exceeds the 64 KB limit.429 RATE_LIMIT_EXCEEDED — rate limit exceeded (60 req/min).The Markdown source is parsed into an abstract syntax tree following CommonMark block and inline rules — block structure (headings, lists, fences, block quotes) is resolved first, then inline structure (emphasis, links, code spans) inside each block. The tree is then rendered to HTML, which is why malformed nesting produces predictable output instead of a parse failure: Markdown has no invalid documents, only documents that mean something other than you intended.
Output is sanitized after rendering. CommonMark permits raw HTML passthrough, so an untrusted document can contain script tags, event-handler attributes and javascript: URLs. The renderer strips those against an allowlist of elements and attributes, which is the difference between a Markdown renderer and a stored-XSS vulnerability in any application that displays user-submitted content.
Table alignment, nested list indentation and fenced-code language hints are the three things that look right in an editor and wrong on the host. Rendering locally catches them before the commit.
Authors write Markdown, the CMS stores HTML. Converting at the boundary keeps the source-of-truth in version control while satisfying the platform.
Markdown gives users formatting without giving them HTML. The sanitization step is what makes that safe; verify here that the tags you expect to be stripped actually are.
HTML email needs inline styles and a restricted tag set. Convert first, then inline the CSS — the converted output shows exactly which elements you need rules for.
What this tool deliberately does not do, and where it will disagree with other implementations.