Skip to main content

Images

Images are embedded inline within paragraph text using the [image] tag. They can appear in paragraphs, table cells, columns layouts, headers, and footers.

Inline syntax

[image, path, width|height]

The [img] shorthand is also supported:

[img, path, width|height]
ParameterDescription
pathPath or URL to the image file
width|heightDimensions in points, separated by a pipe character

Supported formats

FormatExtension
PNG.png
JPEG.jpg, .jpeg
TIFF.tiff, .tif
GIF.gif
SVG.svg

Examples

Image in a paragraph

{ "p": "[image, /assets/logo.png, 120|40]" }

Image with surrounding text

{ "p": "Approved by [image, /assets/signature.png, 80|30] on March 30, 2026." }

Small inline icon

{ "p": "[image, /assets/check-icon.png, 12|12] Shipment verified and dispatched." }

Images in table cells

Place images in table cells alongside other content.

{
"table": {
"widths": [1, 3, 1],
"rows": [
[
{ "p": "[image, /assets/product-a.png, 50|50]" },
{ "p": "[b]Product A[/b][br]Industrial-grade shipping container, 40ft standard." },
{ "p": "$1,200" }
],
[
{ "p": "[image, /assets/product-b.png, 50|50]" },
{ "p": "[b]Product B[/b][br]Refrigerated container, 20ft with temperature control." },
{ "p": "$2,800" }
]
]
}
}

Images in columns layouts

{
"columns": {
"widths": [1, 2],
"gap": 20,
"rows": [
[
{ "p": "[image, /assets/warehouse.png, 150|100]" }
],
[
{ "p": "[b]Chicago Distribution Center[/b]" },
{ "p": "Our flagship facility in the Midwest handles over 50,000 packages per day with automated sorting and climate-controlled storage." }
]
]
}
}

Images in headers

Images are commonly used in headers for company logos. Combine with [tab] to position the logo on the left and text on the right.

{
"header": {
"content": [
{
"p": "[image, /assets/logo.png, 80|24][tab, 350, 0]ShipForge Logistics"
}
],
"separator": {
"lineType": "SOLID",
"length": 500,
"width": 0.5,
"color": "#CCCCCC"
}
}
}

Images with data references

Image paths can include $data references for dynamic image selection.

{ "p": "[image, $data.company.logoUrl, 100|30]" }

Full example

{
"document": {
"styles": {
"title": { "fontSize": 18, "bold": true },
"body": { "fontSize": 10, "color": "#333333" }
},
"header": {
"content": [
{ "p": "[image, /assets/shipforge-logo.png, 90|28][tab, 380, 0][fontcolor, #999999]Shipping Report[/fontcolor]" }
],
"separator": { "lineType": "SOLID", "length": 500, "width": 0.5, "color": "#E0E0E0" },
"skipPages": [1]
},
"content": [
{ "p": "[image, /assets/shipforge-logo.png, 180|56]" },
{ "p": "Quarterly Shipping Report", "style": "title" },
{ "p": "Below is a summary of our hub locations and their current throughput.", "style": "body" },
{
"table": {
"widths": [1, 2, 2],
"rows": [
[
{ "p": "" },
{ "p": "[b]Location[/b]" },
{ "p": "[b]Packages/Day[/b]" }
],
[
{ "p": "[image, /assets/flag-us.png, 24|16]" },
{ "p": "Chicago, IL" },
{ "p": "52,000" }
],
[
{ "p": "[image, /assets/flag-ca.png, 24|16]" },
{ "p": "Toronto, ON" },
{ "p": "34,000" }
],
[
{ "p": "[image, /assets/flag-gb.png, 24|16]" },
{ "p": "London, UK" },
{ "p": "47,000" }
]
]
}
}
]
}
}