Mealie MCP Server
Provides tools to search, create, import, and update recipes in a Mealie recipe manager instance.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Mealie MCP ServerSearch for vegan curry recipes"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Mealie MCP Server
An MCP (Model Context Protocol) server that connects Claude and other MCP clients to your Mealie recipe manager instance. Search, create, import, and update recipes through natural language.
Features
Get Recipe — Retrieve full recipe details by slug or ID
Search Recipes — Free-text search with filtering by category, tag, food, and tool
Create Recipe — Create recipes from structured data (name, ingredients, instructions, etc.)
Import Recipe — Import recipes by URL (Mealie scrapes the page automatically)
Update Recipe — Modify any field on an existing recipe
Related MCP server: Mealie MCP Server
Prerequisites
Mealie v1+ instance running and accessible
A Mealie API token (generate at
<your-mealie-url>/user/profile/api-tokens)Node.js 20+ (for local usage) or Docker
Transports
The server supports two transports:
Transport | Use case | Entry point |
stdio (default) | Claude Desktop, Claude Code, local MCP clients |
|
Streamable HTTP | Claude.ai web/mobile, remote access, multi-user |
|
Authentication
There are two separate auth layers — one for the server to talk to Mealie, and one for clients to talk to the server:
Claude.ai ──OAuth 2.0──▶ MCP Server ──API Token──▶ MealieMealie API Token (
MEALIE_API_TOKEN) — The server's backend credential for accessing Mealie's REST API. Required for both transports. Generate one at<your-mealie-url>/user/profile/api-tokens.OAuth 2.0 + PKCE (HTTP transport only) — How remote clients like Claude.ai authenticate to the MCP server. Users log in with their Mealie username and password via a browser-based flow. The server validates credentials against Mealie and issues OAuth tokens. Not used with stdio transport.
In short: the API token lets the server access recipes, and OAuth lets users prove who they are.
Configuration
Copy .env.example to .env and fill in your values:
cp .env.example .envEnvironment variables
Variable | Required | Description |
| Yes | Base URL of your Mealie instance (e.g. |
| Yes | Your Mealie API token |
| HTTP mode only | Public URL of this server (e.g. |
| No | HTTP server port (default: |
| No | Set to |
Usage
With Claude Desktop (stdio)
Add to your claude_desktop_config.json:
Using Docker:
{
"mcpServers": {
"mealie": {
"command": "docker",
"args": [
"run", "-i", "--rm",
"-e", "MEALIE_URL",
"-e", "MEALIE_API_TOKEN",
"mealie-mcp-server"
],
"env": {
"MEALIE_URL": "http://your-mealie-instance:9925",
"MEALIE_API_TOKEN": "your-api-token"
}
}
}
}Using Node.js directly:
{
"mcpServers": {
"mealie": {
"command": "node",
"args": ["/path/to/mealie-mcp-server/build/index.js"],
"env": {
"MEALIE_URL": "http://your-mealie-instance:9925",
"MEALIE_API_TOKEN": "your-api-token"
}
}
}
}With Claude Code (stdio)
claude mcp add mealie -- node /path/to/mealie-mcp-server/build/index.js \
-e MEALIE_URL=http://your-mealie-instance:9925 \
-e MEALIE_API_TOKEN=your-api-tokenHTTP Transport (Claude.ai web / remote access)
The HTTP transport uses OAuth 2.0 with PKCE, with Mealie credentials as the identity provider. Users authenticate via a login page using their Mealie username and password. This makes it compatible with Claude.ai (web and mobile), which requires OAuth-capable MCP servers.
Requirements: The server must be reachable at a public HTTPS URL (MCP_SERVER_URL).
Using Node.js:
MEALIE_URL=http://your-mealie:9925 \
MEALIE_API_TOKEN=your-api-token \
MCP_SERVER_URL=https://mcp.your-domain.com \
node build/http.jsUsing Docker:
docker run --rm \
-p 3000:3000 \
-e TRANSPORT=http \
-e MEALIE_URL=http://your-mealie:9925 \
-e MEALIE_API_TOKEN=your-api-token \
-e MCP_SERVER_URL=https://mcp.your-domain.com \
mealie-mcp-serverUsing Docker Compose:
# Set env vars in .env file, then:
docker compose up mealie-mcp-server-httpConnecting Claude.ai to the HTTP endpoint:
In Claude.ai settings, add a new MCP server pointing at https://mcp.your-domain.com/mcp. Claude.ai will discover the OAuth metadata automatically and prompt you to log in with your Mealie credentials.
Nginx configuration:
See nginx-mcp.conf.example for the location blocks needed to proxy MCP and OAuth traffic when running behind nginx.
A health check endpoint is available at GET /health.
Note on auth state: The HTTP server stores OAuth tokens in memory. Restarting the server invalidates all existing sessions and requires clients to re-authenticate.
Tools
get_recipe
Get a recipe by its slug or ID.
Parameter | Type | Required | Description |
| string | Yes | Recipe slug or UUID |
search_recipes
Search and list recipes with optional filters.
Parameter | Type | Required | Description |
| string | No | Free-text search query |
| string[] | No | Filter by category slugs or IDs |
| string[] | No | Filter by tag slugs or IDs |
| string[] | No | Filter by food slugs or IDs |
| string[] | No | Filter by tool slugs or IDs |
| boolean | No | Require all specified categories |
| boolean | No | Require all specified tags |
| number | No | Page number (default: 1) |
| number | No | Results per page (default: 50) |
| string | No | Sort field (e.g. |
|
| No | Sort direction |
create_recipe
Create a recipe from structured data.
Parameter | Type | Required | Description |
| string | Yes | Recipe name |
| string | No | Short description |
| string | No | Yield (e.g. "4 servings") |
| string | No | Prep time |
| string | No | Cook time |
| string | No | Total time |
| object[] | No | Ingredients list |
| object[] | No | Instruction steps |
| object | No | Nutritional info |
| object[] | No | Categories |
| object[] | No | Tags |
| object[] | No | Recipe notes |
import_recipe
Import a recipe by URL. Mealie scrapes the page and extracts recipe data.
Parameter | Type | Required | Description |
| string | Yes | URL of the recipe page |
| boolean | No | Extract tags from the page |
| boolean | No | Extract categories from the page |
update_recipe
Update fields on an existing recipe. Only provided fields are changed.
Parameter | Type | Required | Description |
| string | Yes | Recipe slug or UUID to update |
| string | No | New name |
| string | No | New description |
| string | No | New yield |
| string | No | New prep time |
| string | No | New cook time |
| object[] | No | Replacement ingredients |
| object[] | No | Replacement instructions |
| object | No | Nutritional info |
| object[] | No | Categories |
| object[] | No | Tags |
| object[] | No | Notes |
Development
Setup
npm installBuild
npm run buildRun in development
# stdio transport
MEALIE_URL=http://localhost:9925 MEALIE_API_TOKEN=your-token npm run dev
# HTTP transport
MEALIE_URL=http://localhost:9925 MEALIE_API_TOKEN=your-token \
MCP_SERVER_URL=http://localhost:3000 npm run dev:httpTest
npm test
# With coverage
npm run test:coverage
# Watch mode
npm run test:watchDocker
# Build the image
docker build -t mealie-mcp-server .
# Run (stdio)
docker run -i --rm \
-e MEALIE_URL=http://your-mealie:9925 \
-e MEALIE_API_TOKEN=your-token \
mealie-mcp-server
# Run (HTTP with OAuth)
docker run --rm -p 3000:3000 \
-e TRANSPORT=http \
-e MEALIE_URL=http://your-mealie:9925 \
-e MEALIE_API_TOKEN=your-token \
-e MCP_SERVER_URL=https://mcp.your-domain.com \
mealie-mcp-serverArchitecture
src/
├── index.ts # stdio entry point
├── http.ts # HTTP entry point (Streamable HTTP transport + OAuth)
├── server.ts # Creates MCP server and registers all tools (transport-agnostic)
├── mealie-client.ts # HTTP client for the Mealie REST API
├── types.ts # TypeScript type definitions for Mealie API shapes
├── auth/
│ ├── provider.ts # OAuth 2.0 provider (validates Mealie credentials, issues tokens)
│ └── login-page.ts # HTML login page rendered during OAuth authorization flow
└── tools/
├── get-recipe.ts # get_recipe tool
├── search-recipes.ts # search_recipes tool
├── create-recipe.ts # create_recipe tool
├── import-recipe.ts # import_recipe tool
└── update-recipe.ts # update_recipe toolThe server core (server.ts) is transport-agnostic — it builds the MCP server and registers tools without knowing which transport will be used. The two entry points (index.ts for stdio, http.ts for HTTP) each wire in their respective transport.
stdio communicates via stdin/stdout using JSON-RPC 2.0. Standard for Claude Desktop and local MCP clients.
Streamable HTTP exposes a
/mcpendpoint supporting POST (requests), GET (SSE stream), and DELETE (session termination). Uses stateful sessions withMcp-Session-Idheaders. Full OAuth 2.0 + PKCE authentication using Mealie credentials as the identity provider.
License
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/rorymcdaniel/mealie-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server