---
title: Deploy Meilisearch with AI on Blossom
url: "/deploy/meilisearch/"
canonical_url: https://docs.blossom88.com/deploy/meilisearch/
markdown_url: https://docs.blossom88.com/deploy/meilisearch.md
summary: Deploy Meilisearch with AI on Blossom. Add typo-tolerant search to your app
  with persistent indexes and restricted API keys.
categories:
- deployment
- developer-tools
---

# Deploy Meilisearch with AI on Blossom

[Meilisearch](https://www.meilisearch.com/) is a search engine for applications
and websites. Index your products, articles, or other records, then search them
with typo tolerance, filters, and ranking.

It's written in Rust and stores its indexes in an embedded LMDB database.
It doesn't need a separate PostgreSQL or Redis instance. Browse the
[source on GitHub](https://github.com/meilisearch/meilisearch).

This setup uses a [Persistent Service](/docs/apps/persistent-services/)
to keep indexes, settings, and API-key records across Container replacement.

[Install the Blossom CLI and skill](/learn/getting-started/install/)
on your agent's machine and choose a Blossom Cloud Location when you log in.
You can also use
[Blossom BYOC (bring your own cloud)](/learn/getting-started/choose-your-cloud/#blossom-byoc).

## Ask Your Agent

> **Ask your AI agent:** Deploy Meilisearch on Blossom and help me add search to my app.

> Follow this guide: https://docs.blossom88.com/deploy/meilisearch/



Your agent checks the current
[self-hosting requirements](https://www.meilisearch.com/docs/resources/self_hosting/getting_started/docker),
chooses a maintained release, and saves the configuration.

| Part | Purpose |
|---|---|
| Meilisearch Service | Indexing and search API |
| Persistent Volume | Index files, settings, and API-key records |

Run in production mode with a strong, stable master key. Keep administration
behind **Blossom Account access**. Give your backend a restricted indexing key
and your search client a separate, index-scoped search-only key. Keep the
master key in a private file; it does not belong in browser code.

## Search Your First Records

> **Ask your AI agent:** Help me index sample products, search with a typo, and filter the results by category.

> Follow this guide: https://docs.blossom88.com/deploy/meilisearch/



Wait for the indexing task to succeed, then query your index. Configure the
attributes you want to filter before sending a filtered search.

![A sample product-search client querying Meilisearch for “backpak” and returning two backpack matches.](/assets/images/guides/meilisearch/product-search.png)

For public product search, allow only the index's search path through Blossom
Account access, such as `/indexes/products/search`. Meilisearch still requires
the restricted search key. Keep write and administration routes private, and
index only information you intend that client to retrieve.

<details class="optional-reading" markdown="1">
<summary>Commands behind the deployment</summary>

Create a prebuilt-image Environment and a Persistent Service:

    blossom app:create --data app.yml
    blossom environment:create --data environment.yml
    blossom env_var:push --environment environment-100 --file .env.production
    blossom service:create --data meilisearch-service.yml
    blossom environment:deploy --id environment-100 --follow

Set `MEILI_ENV=production`, `MEILI_MASTER_KEY`, and
`MEILI_HTTP_ADDR=0.0.0.0:7700`. Mount a Volume at `/meili_data` and keep
`MEILI_DB_PATH` under that mount. Choose indexing memory and concurrency for
your workload. Use the image's supported entrypoint and an HTTP health check
against `/health`.

Create index-scoped API keys through Meilisearch's `/keys` API. Use the master
key only for key administration. Wait for each asynchronous index/settings
operation's task to succeed before testing its results.

For a public search client, configure the exact search-path exception:

access.yml:

```yaml
environment:
  access_mode: members
  access_public_paths:
    - /indexes/products/search
```

    blossom environment:update --id environment-100 --data access.yml

Send queries with a search-only key for `products`. Confirm that the same key
cannot add documents or search another index. A public-path exception opens
the route; it does not remove Meilisearch's own API-key requirement.

</details>

## Keep Your Index Through Updates

> **Ask your AI agent:** Update Meilisearch and check that my index, search settings, and API keys still work.

> Follow this guide: https://docs.blossom88.com/deploy/meilisearch/



Keep the Volume and master key. Run one active Container for this recipe;
stop it before starting its replacement. Follow the selected release's
[upgrade instructions](https://www.meilisearch.com/docs/resources/migration/updating)
when an update changes the database format.

Search existing records again, check the filters, and index a new record to
confirm that the replacement can keep working.

## What You Get

- Typo-tolerant search with filters for your application
- Separate indexing and search-only API keys
- Private administration with a public search route when needed
- Saved indexes and settings that survive Container replacement
