Skip to main content

MCP server for reading metadata from files using ExifTool

Project description

MCP ExifTool Server

mcp-name: io.github.joshmsimpson/exiftool

An MCP (Model Context Protocol) server that provides access to ExifTool for reading, writing, and removing metadata from a wide range of file types.

Features

  • Read metadata from over 150 file formats
  • Write metadata to files with automatic backup creation
  • Remove metadata selectively or completely from files
  • Extract specific tags or retrieve all available metadata
  • Support for multiple metadata standards: EXIF, IPTC, XMP, GPS, and manufacturer-specific formats

Supported File Formats

Image Formats:

  • RAW Camera Formats: ARW, CR2, CR3, CRW, DNG, ERF, FFF, GPR, IIQ, K25, KDC, MEF, MRW, NEF, NRW, ORF, PEF, RAF, RAW, RW2, RWL, SR2, SRF, SRW, X3F
  • Raster Images: BMP, FLIF, GIF, HDR, HEIC, HEIF, JPEG, JPEG 2000, JXL, JXR, PCX, PGF, PNG, PPM, TIFF, WebP
  • Specialized Images: AVIF, BPG, DPX, EXR, FITS, FLIR, FPX, ICO, LFP, MIFF, PSD, PSP, QTIF, SVG

Video Formats:

  • Containers: 3GP, AVI, F4V, FLV, GLV, M2TS, MOV, MP4, MKV, MPEG, R3D, VOB, WebM, WTV
  • Other Video: DV, DVR-MS, INSV, LRV, MQV

Audio Formats:

  • Lossless: AIFF, FLAC, LA, OFR, PAC, WAV, WV
  • Lossy: AAC, APE, DSF, M4A, MP3, MPC, OGG, OPUS, RA, WMA

Document Formats:

  • Office: DOC, DOCX, XLSX, PPTX, XLS, KEY, NUMBERS, PAGES
  • Other Documents: PDF, EPS, RTF, TXT, XML, JSON
  • eBooks: EPUB, MOBI, AZW

Archive Formats:

  • 7z, GZ, RAR, ZIP

Other Formats:

  • Fonts: AFM, OTF, PFA, TTF
  • And many more specialized formats

Prerequisites

ExifTool must be installed on your system. This MCP server is a wrapper that calls the ExifTool command-line tool.

Installing ExifTool

macOS:

brew install exiftool

Ubuntu/Debian:

sudo apt-get install libimage-exiftool-perl

Windows: Download from https://exiftool.org/

Verify installation:

exiftool -ver

Installation

pip install exiftool-mcp

Usage

With Claude Desktop

Add this to your claude_desktop_config.json:

{
  "mcpServers": {
    "exiftool": {
      "command": "exiftool-mcp"
    }
  }
}

With Other MCP Clients

The server communicates via stdio and follows the Model Context Protocol specification.

Available Tools

read_metadata

Read metadata from a file using ExifTool.

Parameters:

  • file_path (required): Path to the file (absolute or relative)
  • tags (optional): Array of specific metadata tags to extract (e.g., ["DateTimeOriginal", "Make", "Model"])

Example:

{
  "file_path": "/path/to/image.jpg",
  "tags": ["DateTimeOriginal", "Make", "Model", "GPSLatitude", "GPSLongitude"]
}

write_metadata

Write or update metadata tags in a file using ExifTool. Creates a backup by default.

Parameters:

  • file_path (required): Path to the file (absolute or relative)
  • tags (required): Dictionary of metadata tags to write (e.g., {"Artist": "John Doe", "Copyright": "2025"})
  • overwrite_original (optional): If true, overwrites the original file without creating a backup. Default is false.

Example:

{
  "file_path": "/path/to/image.jpg",
  "tags": {
    "Artist": "John Doe",
    "Copyright": "2025",
    "Comment": "Beautiful sunset"
  },
  "overwrite_original": false
}

remove_metadata

Remove metadata from a file using ExifTool. Can remove all metadata or specific tags.

Parameters:

  • file_path (required): Path to the file (absolute or relative)
  • tags (optional): Array of specific metadata tags to remove (e.g., ["GPS*", "Comment"]). If not specified, all metadata is removed.
  • overwrite_original (optional): If true, overwrites the original file without creating a backup. Default is false.

Example:

{
  "file_path": "/path/to/image.jpg",
  "tags": ["GPS*", "Location*"],
  "overwrite_original": false
}

list_supported_formats

List all file formats supported by ExifTool.

Parameters: None

Examples

Reading all metadata from an image

Use the read_metadata tool with file_path: "photo.jpg"

Reading specific EXIF tags

Use the read_metadata tool with:
- file_path: "photo.jpg"
- tags: ["DateTimeOriginal", "Make", "Model", "LensModel"]

Writing metadata to a file

Use the write_metadata tool with:
- file_path: "photo.jpg"
- tags: {"Artist": "Jane Smith", "Copyright": "2025", "Rating": "5"}

Removing GPS data from a photo

Use the remove_metadata tool with:
- file_path: "photo.jpg"
- tags: ["GPS*"]

Removing all metadata from a file

Use the remove_metadata tool with:
- file_path: "photo.jpg"
(no tags specified removes all metadata)

Checking supported formats

Use the list_supported_formats tool

Development

Setup

git clone https://github.com/joshmsimpson/exiftool_mcp.git
cd exiftool_mcp
pip install -e .

Running locally

python -m exiftool_mcp.server

License

MIT

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

exiftool_mcp-0.1.6.tar.gz (8.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

exiftool_mcp-0.1.6-py3-none-any.whl (7.4 kB view details)

Uploaded Python 3

File details

Details for the file exiftool_mcp-0.1.6.tar.gz.

File metadata

  • Download URL: exiftool_mcp-0.1.6.tar.gz
  • Upload date:
  • Size: 8.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for exiftool_mcp-0.1.6.tar.gz
Algorithm Hash digest
SHA256 683e5bf80d7f53a9c144e541e63f7e91a3edce33abfd5449c869b96538cf0880
MD5 69272535c76af50686f9773fdc092037
BLAKE2b-256 99d15150088d55b6d95c2afc1b04b2b5fc3bedd8f73f4062d9f9e77851cac3ef

See more details on using hashes here.

File details

Details for the file exiftool_mcp-0.1.6-py3-none-any.whl.

File metadata

  • Download URL: exiftool_mcp-0.1.6-py3-none-any.whl
  • Upload date:
  • Size: 7.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for exiftool_mcp-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 5a3bf1f8bd8d2d6888c969c0c5bee4ae0ce43e0de6b64120057c153c2f3d7ccd
MD5 9dc7097dc01623e20045a0977ec29c85
BLAKE2b-256 56eb4489fc15654e950c5e056002712c9a49e3da1efd5f472999e8f1508f3879

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page