---
title: "Image libraries, MailKaro Docs"
description: "Image libraries in MailKaro: add an Amazon S3 tab for your bucket, or open your own media library from image and GIF blocks."
---

# Image libraries

Content & assets

# Image libraries

Add your own image sources to the editor: an Amazon S3 bucket, or your own media library.

The asset dialog has tabs per source. Pass `s3` to add an **Amazon S3** tab for your bucket (see [Amazon S3](https://mailkaro.com/docs/amazon-s3)), or open your own library from image and GIF blocks, as below.

## Your own library

To open your own media library instead of the built-in one, register Unlayer's `selectImage` callback. "Open Library" on an image or GIF block then calls it. Call `done` with the chosen image, with `{ error }`, or with no `url` to leave the image as it was.

tsx

```
<EmailEditor
 token="pk_live_…"
 onReady={(editor) => {
 editor.registerCallback("selectImage", (data, done) => {
 // data.kind is "image" or "gif"; openMyLibrary is your own picker
 openMyLibrary(data.kind).then((picked) => done({ url: picked.url, alt: picked.alt }));
 });
 }}
/>
```

For buckets and upload handlers, see [custom file storage](https://mailkaro.com/docs/custom-file-storage); for stock photos, see [stock images](https://mailkaro.com/docs/stock-images).

Source: https://docs.mailkaro.com/image-libraries
