Resources »

Solutions Hub »

Automations »

Convert Markdown to HTML

Using |markdown_to_html filter

Here is an example of using the |markdown_to_html filter to convert Markdown content into HTML format.

The is_untrusted parameter sanitizes HTML output (e.g. script blocks and images).

  • 
    start:
      set:
        markdown_text@text:
          # Title
          This is a **Markdown** message.
      return:
        output: {{markdown_text|markdown_to_html(is_untrusted=true)}}
    
    
  • 
    __return:
      output: |-
        <h1>Title</h1>
        <p>This is a <strong>Markdown</strong> message.</p>