# FatSecret

> FatSecret is an open-source MCP server for health and science. MCP server connecting AI assistants to the FatSecret food, diary and weight API. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, API, macOS, Windows, Linux, Self-hosted
- **Repository:** https://github.com/kondratjev/fatsecret-mcp-go
- **MCP Registry name:** io.github.kondratjev/fatsecret-mcp-go
- **Categories:** [health and science](https://ai-powered.com/categories/health-and-science)
- **Listing updated:** 2026-11-27

## About

Gives an AI assistant access to the FatSecret Platform API for nutrition work. Once connected, a client can search foods and barcodes, look up recipes, and read or write food diary, saved meal, weight and exercise entries for a signed-in account. The server is written in Go and ships as a single binary or Docker image, and it can run over stdio or Streamable HTTP.

Writes are staged first. A draft is created with a validated preview, and it only takes effect when confirmed. An environment flag can disable direct writes entirely. For households, one HTTP server can host several members, each authorizing their own FatSecret profile through a request header.

It suits people who track their diet with an AI client and want logging to go through a conversation, as well as developers who need a self-hosted FatSecret bridge. It is not an official FatSecret product, and it needs a free FatSecret developer key to function.

## Features

- **Food and barcode search:** Finds foods by name or GTIN-13 barcode and returns nutrition details.
- **Diary and meal logging:** Adds, edits, copies and deletes food diary entries, and logs whole meals in one call.
- **Weight and exercise tracking:** Records weight history and manages exercise entries and templates.
- **Staged write confirmation:** Previews changes as drafts that must be confirmed before they are saved.
- **Household profiles:** Lets several people share one server, each with their own authorized account.
- **Stdio and HTTP transports:** Runs locally for desktop clients or as a self-hosted remote endpoint.

## Good for

- Logging a meal by describing it to an AI assistant
- Reviewing daily or monthly calorie and macro totals
- Building saved meals and favorites for quick logging
- Tracking weight trends alongside diary data
- Looking up nutrition facts for a packaged food by barcode

## Install

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

```sh
claude mcp add fatsecret-mcp-go --env FATSECRET_CLIENT_ID='<FATSECRET_CLIENT_ID>' --env FATSECRET_CLIENT_SECRET='<FATSECRET_CLIENT_SECRET>' --env FATSECRET_CONSUMER_SECRET='<FATSECRET_CONSUMER_SECRET>' -- docker run -i --rm -e FATSECRET_CLIENT_ID -e FATSECRET_CLIENT_SECRET -e FATSECRET_CONSUMER_SECRET ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0
```

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-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go": {
      "type": "stdio",
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go --env FATSECRET_CLIENT_ID='<FATSECRET_CLIENT_ID>' --env FATSECRET_CLIENT_SECRET='<FATSECRET_CLIENT_SECRET>' --env FATSECRET_CONSUMER_SECRET='<FATSECRET_CONSUMER_SECRET>' -- docker run -i --rm -e FATSECRET_CLIENT_ID -e FATSECRET_CLIENT_SECRET -e FATSECRET_CONSUMER_SECRET ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0
```

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

```toml
[mcp_servers.fatsecret-mcp-go]
command = "docker"
args = ["run", "-i", "--rm", "-e", "FATSECRET_CLIENT_ID", "-e", "FATSECRET_CLIENT_SECRET", "-e", "FATSECRET_CONSUMER_SECRET", "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"]
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-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go docker -- run -i --rm -e FATSECRET_CLIENT_ID -e FATSECRET_CLIENT_SECRET -e FATSECRET_CONSUMER_SECRET ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0

### Gemini CLI and Antigravity: Antigravity (~/.gemini/config/mcp_config.json)

```json
{
  "mcpServers": {
    "fatsecret-mcp-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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-go": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "FATSECRET_CLIENT_ID",
        "-e",
        "FATSECRET_CLIENT_SECRET",
        "-e",
        "FATSECRET_CONSUMER_SECRET",
        "ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0"
      ],
      "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, 2 of 12 tools change data; 3 names don't say. From the server's own tool labels and tool names; not verified by us.

- `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 food by GTIN-13 barcode
- `search_recipes` (name suggests: reads): Search recipes with filters
- `get_recipe` (name suggests: reads): Get recipe details with ingredients and directions
- `log_meal`: Log a whole meal in one call and get day totals
- `get_food_entries` (name suggests: reads): Get food diary entries for a date
- `create_food_entry` (name suggests: changes): Add a food diary entry
- `update_weight` (name suggests: changes): Record weight for a date
- `get_weight_month` (name suggests: reads): Get weight history for a month
- `prepare_call`: Stage a write as a single-use draft
- `confirm_draft`: Execute a draft staged by prepare_call

## FAQ

### Is this an official FatSecret server?

No. It is an independent project that uses the FatSecret Platform API, which requires a free developer account.

### Do I need a paid FatSecret plan?

A free API key works. Some features, such as branded foods, text parsing and image recognition, need Premier or paid add-ons.

### Can FatSecret change my diary without asking?

Writes are staged as drafts and only take effect after confirmation. An environment setting can block direct writes entirely.

### Which clients can use FatSecret?

Any MCP-compatible client, including Claude Desktop, Claude Code, Cursor and OpenCode.

### How do I add FatSecret to Claude Code?

Run this command in your terminal: claude mcp add fatsecret-mcp-go --env FATSECRET_CLIENT_ID='<FATSECRET_CLIENT_ID>' --env FATSECRET_CLIENT_SECRET='<FATSECRET_CLIENT_SECRET>' --env FATSECRET_CONSUMER_SECRET='<FATSECRET_CONSUMER_SECRET>' -- docker run -i --rm -e FATSECRET_CLIENT_ID -e FATSECRET_CLIENT_SECRET -e FATSECRET_CONSUMER_SECRET ghcr.io/kondratjev/fatsecret-mcp-go:0.2.0

### What are the best alternatives to FatSecret?

The closest alternatives to FatSecret are Fatsecret MCP, Fatsecret MCP, MyFitnessPal MCP, BasalFit and Sphere.

## Where this comes from

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

## Alternatives

- [Fatsecret MCP](https://ai-powered.com/mcp/fatsecret-mcp): Fatsecret MCP is an open-source MCP server for health and science.
- [Fatsecret MCP](https://ai-powered.com/mcp/fatsecret-mcp-2): Fatsecret MCP is an open-source MCP server for food and drink.
- [MyFitnessPal MCP](https://ai-powered.com/mcp/myfitnesspal-mcp): MyFitnessPal MCP is an open-source MCP server for health and science.
- [BasalFit](https://ai-powered.com/mcp/basalfit): BasalFit is a free MCP server for health and science.
- [Sphere](https://ai-powered.com/mcp/sphere): Sphere is an MCP server for health and science.
- [Cronometer Api MCP](https://ai-powered.com/mcp/cronometer-api-mcp): Cronometer Api MCP is an open-source MCP server for health and science.
- [Nutrition MCP](https://ai-powered.com/mcp/nutrition-mcp-2): Nutrition MCP is an open-source MCP server for health and science.
- [Mouve](https://ai-powered.com/mcp/mouve): Mouve is a freemium MCP server for health and science.

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