Skip to main content
Images and visual content help make your documentation more engaging and easier to understand. Mintlify supports multiple ways to add images and embed media.

Images

You can add images using markdown syntax or HTML for more customization options.

Using markdown

The markdown syntax lets you add images using the following code:
![title](/path/image.jpg)
The image file size must be less than 5MB. Otherwise, we recommend hosting on a service like Cloudinary or S3.

Using HTML embeds

To get more customizability with images, you can also use HTML <img> tags to add images with custom styling:
<img height="200" src="/path/image.jpg" />
<img src="/path/image.jpg" />
Simple image with default styling.

Image hosting

For larger images or better performance, consider using a CDN or cloud storage service:

Recommended hosting services

  • Cloudinary - Image optimization and CDN
  • AWS S3 - Scalable cloud storage
  • Imgur - Simple image hosting
  • GitHub - Host images in your repository
Using a CDN ensures fast image loading times for users around the world.

Embeds and HTML elements


Mintlify supports HTML tags in Markdown. This is helpful if you prefer HTML tags to Markdown syntax, and lets you create documentation with infinite flexibility.

iFrames

Loads another HTML page within the document. Most commonly used for embedding videos.
<iframe src="https://www.youtube.com/embed/4KzFe50RQkQ"> </iframe>
<iframe
  width="560"
  height="315"
  src="https://www.youtube.com/embed/VIDEO_ID"
  title="YouTube video player"
  frameBorder="0"
  allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
  allowFullScreen
></iframe>
When embedding content from external sources, ensure the source is trusted and the content is appropriate for your documentation.

Best practices

  • Keep image file sizes under 5MB
  • Use appropriate image formats (JPEG for photos, PNG for graphics)
  • Consider using WebP for better compression
  • Host large images on a CDN

Build docs developers (and LLMs) love