# Fatsecret MCP

> Fatsecret MCP is an open-source MCP server for health and science. Unofficial FatSecret server for food search, diary, recipes and weight logging. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, API, macOS
- **Repository:** https://github.com/fliptheweb/fatsecret-mcp
- **MCP Registry name:** io.github.fliptheweb/fatsecret-mcp
- **Categories:** [health and science](https://ai-powered.com/categories/health-and-science), [food and drink](https://ai-powered.com/categories/food-and-drink)
- **Listing updated:** 2026-11-23

## About

The server wraps the FatSecret Platform API rather than shipping its own food data, so it needs a free developer account and three credentials: a client ID, a client secret for OAuth 2.0 and a consumer secret for OAuth 1.0. Public lookups such as food search, barcode search and recipes use the OAuth 2.0 side, while personal diary and weight tools need a profile authorization.

On first use the assistant can walk you through setup itself: it checks auth status, stores the keys in a local config file under your home folder, then starts and completes the OAuth flow with a PIN. Keys can also be passed as environment variables. If your FatSecret app has Premier access, the server asks for the premier scope and falls back to basic when it is rejected.

It is an unofficial project, not made by FatSecret. It runs over stdio from npm and is also packaged as a Claude Desktop extension.

## Features

- **Food and barcode search:** Search the FatSecret food database, fetch nutrition detail, look up GTIN-13 barcodes and get autocomplete suggestions.
- **Recipe search:** Search recipes with filters and fetch ingredients and directions.
- **Food diary:** Add, edit, delete and copy diary entries, and read a month of daily calories and macros.
- **Saved meals:** Create reusable meals and add, edit or remove their items.
- **Weight and exercise:** Record weight for a date, read monthly history and view or edit exercise entries.
- **Guided credential setup:** Tools check auth status, store API keys and run the OAuth PIN flow from inside the chat.

## Good for

- Log what you ate by telling an assistant instead of using the FatSecret app
- Look up nutrition for a food or packaged product by barcode
- Find recipes within a calorie or macro target
- Review a month of calorie and weight history in a chat
- Copy a saved meal onto several diary dates

## Install

### Claude Code: Add with the CLI (Terminal)

```sh
claude 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
```

Add --scope user to use it in every project, or --scope project to share it in .mcp.json.

### Claude Code: Or share it with your project (.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>"
      }
    }
  }
}
```

### Claude Desktop (claude_desktop_config.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>"
      }
    }
  }
}
```

Settings → Developer → Edit Config, then quit and reopen Claude Desktop.

### Cursor (~/.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>"
      }
    }
  }
}
```

Use .cursor/mcp.json in a project to share it with the project.

### VS Code (~/.copilot/mcp-config.json)

```json
{
  "mcpServers": {
    "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>"
      }
    }
  }
}
```

Or put the same entry in .mcp.json at your workspace root to share it.

### Codex: Add with the CLI (Terminal)

```sh
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
```

### Codex: Or add to config.toml (~/.codex/config.toml)

```toml
[mcp_servers.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>" }
```

### Gemini CLI and Antigravity: Gemini CLI (~/.gemini/settings.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>"
      }
    }
  }
}
```

Or run: gemini mcp add -s user -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

### Gemini CLI and Antigravity: Antigravity (~/.gemini/config/mcp_config.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>"
      }
    }
  }
}
```

Use .agents/mcp_config.json to add it to one workspace only.

### Devin Desktop (~/.config/devin/mcp_config.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>"
      }
    }
  }
}
```

On Windows the file is %APPDATA%\\devin\\mcp_config.json. Use .devin/mcp_config.json to share it with a project.

### Cline (cline_mcp_settings.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>"
      }
    }
  }
}
```

Open it from the MCP Servers icon → Configure → Configure MCP Servers.

### Zed (Zed settings.json)

```json
{
  "context_servers": {
    "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>"
      }
    }
  }
}
```

Open it with zed: open settings file. Merge context_servers into the settings you already have.

### JetBrains AI Assistant and Junie: AI Assistant (Settings → Tools → AI Assistant → Model Context Protocol (MCP) → Add)

```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>"
      }
    }
  }
}
```

The AI Assistant docs only show command and args. If the env block is ignored, use Junie for this server.

### JetBrains AI Assistant and Junie: Junie (~/.junie/mcp/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>"
      }
    }
  }
}
```

Use .junie/mcp/mcp.json to share it with a project.

### Kiro (~/.kiro/settings/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>"
      }
    }
  }
}
```

Use .kiro/settings/mcp.json to add it to one workspace only.

### Other clients (your client's MCP settings (most use this shape))

```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>"
      }
    }
  }
}
```

## Tools

From the tool list in its README, going by the names, 1 of 23 tools deletes data and 6 change data; 4 names don't say. From the server's own tool labels and tool names; not verified by us.

- `check_auth_status` (name suggests: reads): Check whether credentials and profile auth are configured
- `setup_credentials`: Save FatSecret API credentials to persistent config
- `start_auth` (name suggests: changes): Start OAuth 1.0 authorization and return a URL to visit
- `complete_auth`: Complete OAuth with the verifier PIN
- `search_foods` (name suggests: reads): Search the food database
- `get_food` (name suggests: reads): Get detailed nutrition info for a food
- `find_food_by_barcode` (name suggests: reads): Find a food by GTIN-13 barcode
- `autocomplete_foods`: Get search autocomplete suggestions
- `search_recipes` (name suggests: reads): Search recipes with filters
- `get_recipe` (name suggests: reads): Get recipe details with ingredients and directions
- `get_food_entries` (name suggests: reads): Get food diary entries for a date
- `get_food_entries_month` (name suggests: reads): Get a monthly nutrition summary
- `create_food_entry` (name suggests: changes): Add a food diary entry
- `edit_food_entry` (name suggests: changes): Edit a food diary entry
- `delete_food_entry` (name suggests: deletes): Delete a food diary entry
- `copy_food_entries`: Copy entries from one date to another
- `get_saved_meals` (name suggests: reads): Get saved meals
- `create_saved_meal` (name suggests: changes): Create a saved meal
- `update_weight` (name suggests: changes): Record weight for a date
- `get_weight_month` (name suggests: reads): Get weight history for a month
- `get_exercises` (name suggests: reads): Get exercise types
- `get_profile` (name suggests: reads): Get user profile info
- `create_food` (name suggests: changes): Create a custom food (Premier)

## FAQ

### Is this an official FatSecret server?

No. The README states it is not made by FatSecret and uses the FatSecret Platform API.

### What do I need before using Fatsecret MCP?

A free FatSecret developer account with a client ID, client secret and consumer secret.

### Where are my credentials stored?

If you use the setup tool they are saved to a config file in your home directory; you can also pass them as environment variables.

### Does Fatsecret MCP work with free API keys?

Yes. The premier scope is tried first and the server falls back to the basic scope when a free key is rejected.

### How do I install Fatsecret MCP?

Run it with npx fatsecret-mcp from an MCP client config, or install the Claude Desktop extension bundle.

### How do I add Fatsecret MCP to Claude Code?

Run this command in your terminal: claude 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

### What are the best alternatives to Fatsecret MCP?

The closest alternatives to Fatsecret MCP are Tooluniverse, Oya Browser, BasalFit, Alpha-Gal Watch: Alpha-Gal Syndrome Food Check and Renal Diet (CKD) and Alpha-Gal Syndrome Food Check.

## Where this comes from

- Description: written from the project's README.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [Tooluniverse](https://ai-powered.com/mcp/tooluniverse): Tooluniverse is an open-source MCP server for health and science.
- [Oya Browser](https://ai-powered.com/mcp/oya-browser): Oya Browser is a freemium MCP server for browser automation.
- [BasalFit](https://ai-powered.com/mcp/basalfit): BasalFit is a free MCP server for health and science.
- [Alpha-Gal Watch: Alpha-Gal Syndrome Food Check](https://ai-powered.com/mcp/alpha-gal-watch-alpha-gal-syndrome-food-check): Alpha-Gal Watch: Alpha-Gal Syndrome Food Check is an MCP server for food and drink.
- [Renal Diet (CKD) and Alpha-Gal Syndrome Food Check](https://ai-powered.com/mcp/renal-diet-ckd-and-alpha-gal-syndrome-food-check): Renal Diet (CKD) and Alpha-Gal Syndrome Food Check is an MCP server for mcp data access.
- [KidneyWatch Renal Diet (CKD) Food Check](https://ai-powered.com/mcp/kidneywatch-renal-diet-ckd-food-check): KidneyWatch Renal Diet (CKD) Food Check is an MCP server for mcp data access.
- [Diochi — bylinné přípravky, kluby a Sféra](https://ai-powered.com/mcp/diochi-bylinne-pripravky-kluby-a-sfera): Diochi — bylinné přípravky, kluby a Sféra is an MCP server for health and science.
- [APREM: food guide for Armenia](https://ai-powered.com/mcp/aprem-food-guide-for-armenia): APREM: food guide for Armenia is a free MCP server for food and drink.

---
Source: https://ai-powered.com/mcp/fatsecret-mcp
