Skip to content

Image

Display images with optional captions and alt text.

Syntax

Captions are supported by adding a [caption] line immediately below the block.

[image](path/to/image.jpg)
[caption] Caption text

Examples

[image](./assets/screenshot.png)
[caption] Main dashboard view

[image](https://example.com/diagram.svg)
[caption] System architecture

Builder

from notionary.markdown import MarkdownBuilder

markdown = (MarkdownBuilder()
  .h2("Setup Guide")
  .image("./assets/interface.png", "Main dashboard view")
  .paragraph("Navigate using the sidebar.")
  .build())

Reference

Notion API Reference

For the official Notion API reference on image blocks, see https://developers.notion.com/reference/block#image