# fatsecret-mcp

This MCP server connects an AI client to FatSecret for food lookup, recipe search, nutrition data, food diaries, and weight records.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 11
- Author: fliptheweb
- License: MIT · policy=link-only · description only; the file stays with the author
- Source: https://github.com/fliptheweb/fatsecret-mcp
- Updated: 2026-08-01
- HTML: https://affpapa.org/en/nevibecode/mcp/fatsecret-mcp

## What it does

\`fatsecret-mcp` gives an MCP client access to the FatSecret API. An agent can look up foods, read nutrition details, search by GTIN-13 barcode, find recipes, and browse food references. Profile tools cover diary entries, saved meals, favorites, exercise records, weight history, and profile data.

The server runs with `npx -y fatsecret-mcp` and accepts `FATSECRET_CLIENT_ID`, `FATSECRET_CLIENT_SECRET`, and `FATSECRET_CONSUMER_SECRET` as environment variables. You need a free FatSecret developer account to obtain them. Diary and profile features also require OAuth authorization, so those tools will not work from API keys alone.

## Requirements
- Needs: Node.js (commands run via npx)
- Environment variables: `FATSECRET_CLIENT_ID`, `FATSECRET_CLIENT_SECRET`, `FATSECRET_CONSUMER_SECRET` — keys and tokens: ask the human for the values, never commit them or put them in shared files.

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add fatsecret-mcp -e FATSECRET_CLIENT_ID=<FATSECRET_CLIENT_ID> -e FATSECRET_CLIENT_SECRET=<FATSECRET_CLIENT_SECRET> -e FATSECRET_CONSUMER_SECRET=<FATSECRET_CONSUMER_SECRET> -- npx -y fatsecret-mcp
```
Replace <…> with your own values

### Codex

**Platform CLI**
```bash
codex mcp add fatsecret-mcp --env FATSECRET_CLIENT_ID=<FATSECRET_CLIENT_ID> --env FATSECRET_CLIENT_SECRET=<FATSECRET_CLIENT_SECRET> --env FATSECRET_CONSUMER_SECRET=<FATSECRET_CONSUMER_SECRET> -- npx -y fatsecret-mcp
```
Replace <…> with your own values

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "fatsecret-mcp": {
            "command": "npx",
            "args": [
                "-y",
                "fatsecret-mcp"
            ],
            "env": {
                "FATSECRET_CLIENT_ID": "<FATSECRET_CLIENT_ID>",
                "FATSECRET_CLIENT_SECRET": "<FATSECRET_CLIENT_SECRET>",
                "FATSECRET_CONSUMER_SECRET": "<FATSECRET_CONSUMER_SECRET>"
            }
        }
    }
}
```
Replace <…> with your own values

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "fatsecret-mcp": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "fatsecret-mcp"
            ],
            "env": {
                "FATSECRET_CLIENT_ID": "<FATSECRET_CLIENT_ID>",
                "FATSECRET_CLIENT_SECRET": "<FATSECRET_CLIENT_SECRET>",
                "FATSECRET_CONSUMER_SECRET": "<FATSECRET_CONSUMER_SECRET>"
            }
        }
    }
}
```
Replace <…> with your own values

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add -e FATSECRET_CLIENT_ID=<FATSECRET_CLIENT_ID> -e FATSECRET_CLIENT_SECRET=<FATSECRET_CLIENT_SECRET> -e FATSECRET_CONSUMER_SECRET=<FATSECRET_CONSUMER_SECRET> fatsecret-mcp npx -y fatsecret-mcp
```
Replace <…> with your own values

## When to use it
- look up nutrition facts for a food
- identify a product from a GTIN-13 barcode
- search recipes with calorie or macro filters
- add and edit food diary entries
- record weight and inspect monthly history

## Example prompts
- Find the nutrition details for the ingredients in this meal.
- Look up this GTIN-13 barcode and add the food to today’s diary.
- Show my weight history for the month and my recent diary foods.

## Similar
- [REA](https://affpapa.org/en/nevibecode/mcp/rea.md) — MCP server · ★ 392262
- [GitHub](https://affpapa.org/en/nevibecode/mcp/github.md) — MCP server · ★ 33989
- [World Monitor](https://affpapa.org/en/nevibecode/mcp/world-monitor.md) — MCP server · ★ 89609
- [Netdata](https://affpapa.org/en/nevibecode/mcp/netdata.md) — MCP server · ★ 81163
- [Front-End Checklist](https://affpapa.org/en/nevibecode/mcp/front-end-checklist.md) — MCP server · ★ 74569
- [Scrapling MCP Server](https://affpapa.org/en/nevibecode/mcp/scrapling-mcp-server.md) — MCP server · ★ 89899

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
