# Export Markdown Notes to HTML

Combine Markdown notes into one standalone HTML page with embedded CSS, sanitized output and a linked table of contents.

## Run it

- **CLI:** `gizza tool notes-to-html-export "# Project notes

## Decisions

- Use one portable HTML export.

# Meeting notes

## Actions

- [ ] Send the summary."`
- **Web:** https://gizza.ai/tools/notes-to-html-export/
- **Agents:** machine-readable descriptor (parameters JSON Schema) at https://gizza.ai/tools/notes-to-html-export/tool.json

## Inputs

- `notes` — Markdown notes _(field)_
- `split` — Split notes by _(field)_
- `toc` — Table of contents _(field)_
- `toc_depth` — TOC depth (1–6) _(field)_
- `number_sections` — Number sections _(field)_
- `title` — Document title _(field)_
- `theme` — Theme _(field)_

## Output

- Standalone HTML (html)

## Query parameters

Open the tool pre-filled and auto-run via URL:

- `notes` — Markdown notes
- `split` — Split notes by
- `toc` — Table of contents
- `toc_depth` — TOC depth (1–6)
- `number_sections` — Number sections
- `title` — Document title
- `theme` — Theme

Example: `https://gizza.ai/tools/notes-to-html-export/?notes=%23%20Project%20notes%0A%0A%23%23%20Decisions%0A%0A-%20Use%20one%20portable%20HTML%20export.%0A%0A%23%20Meeting%20notes%0A%0A%23%23%20Actions%0A%0A-%20%5B%20%5D%20Send%20the%20summary.&split=heading&toc=sidebar&toc_depth=3&number_sections=true&title=Notes&theme=light`

---

## Bundle Markdown notes into one portable page

Use this exporter when several Markdown notes need to travel as a single file:
meeting notes, a project handbook, a research digest, or a release checklist. It
renders CommonMark plus common GitHub-flavored Markdown features, sanitizes the
HTML, adds stable heading anchors, generates an optional linked table of
contents, and embeds all CSS directly in the output.

### Worked example

Paste notes like this:

```markdown
# Project handbook

## Setup

Run the installer.

## Release checklist

- [ ] Tests pass
- [ ] Changelog updated

# Operations

## Rollback

Restore the previous build.
```

Choose **Split notes by: Level-1 headings**, **Table of contents: Sticky
sidebar**, **TOC depth: 3**, turn on **Number sections**, set the title to
`Project Handbook`, and export. The result is one complete HTML document you can
save as `.html`, send to someone else, or open offline.

### Limits and edge cases

Remote images are not fetched and inlined; images that are already `data:` URIs
stay embedded. Code blocks are styled as readable monospace blocks, but the tool
does not ship a language highlighter. Raw HTML from the notes is sanitized, so
scripts, event handlers and unsafe links are removed before the output is
wrapped.

## FAQ

<details>
<summary>Can I export multiple real files or a folder?</summary>

Paste their Markdown into the notes field. Use level-1 headings when each note
already starts with `# Title`, or thematic breaks (`---`) when you want explicit
boundaries between pasted notes.

</details>

<details>
<summary>Is the output really self-contained?</summary>

Yes. The exporter returns one `<!doctype html>` document with embedded CSS and no
external JavaScript, fonts or stylesheets. Remote images are the exception: the
tool does not fetch and embed them for you.

</details>

<details>
<summary>Why sanitize the Markdown output?</summary>

The exported file is meant to be shared. Sanitizing strips scripts, inline event
handlers and `javascript:` links so a pasted note cannot turn into an active
HTML payload in the final document.

</details>

<details>
<summary>How does the table of contents choose headings?</summary>

Every rendered heading receives a unique slug anchor. The TOC depth controls the
deepest heading level listed, from `1` through `6`; headings deeper than that
still appear in the document but are omitted from the TOC.

</details>

## Related tools

- [Markdown Section Extractor](https://gizza.ai/tools/markdown-section-extractor/): Extract one section from a Markdown document by heading — keep or drop subsections, exact or substring match, ATX and setext. Free, in your browser.
- [Convert Markdown ↔ Jira Wiki Markup](https://gizza.ai/tools/markdown-to-jira/): Convert Markdown to Jira wiki markup and back locally. Handles headings, lists, tables, code blocks, links, images, quotes, and common panels.
- [Mermaid from data](https://gizza.ai/tools/mermaid-from-data/): Turn structured node and edge rows into Mermaid flowchart, classDiagram or erDiagram source with labels, shapes and relationship styles.
- [ISO 9660 TOC List](https://gizza.ai/tools/iso9660-toc-list/): List an ISO 9660 disc image's volume label, directory tree and file sizes from base64 data without extracting files. Browser-local and read-only.
- [HTML Diff](https://gizza.ai/tools/html-diff/): Compare two HTML snippets by their visible text, ignoring tag and attribute noise.
