Skip to main content

banner

PyPI PyPI - Python Version

Product Page | Docs | Demos | API Reference | Blog | Free Support | Temporary License

GroupDocs.Metadata for Python via .NET is a metadata management API that reads, edits, and removes metadata from documents, spreadsheets, presentations, PDFs, images, audio, and video — 110+ file formats. It works with the major metadata standards (XMP, EXIF, IPTC, Image Resource Blocks, ID3, document properties) through one unified, format-independent API.

Get Started

pip install groupdocs-metadata-net
from groupdocs.metadata import Metadata

with Metadata("document.docx") as metadata:
    root = metadata.get_root_package()
    print("Format:", root.file_type.file_format)

How It Works

The package is a self-contained Python wheel (~160 MB) that bundles the embedded .NET runtime and everything needed to process metadata. No external software installation is required — just pip install and start reading metadata. The wheel works across Python 3.5 – 3.14 on Windows, Linux, and macOS (Intel + Apple Silicon).

Features

  • Read, edit, and remove metadata from 110+ formats with one unified API.
  • Metadata standards: XMP, EXIF, IPTC IIM, Image Resource Blocks, ID3 (ID3v1/ID3v2), Lyrics3, APE.
  • Search engine: find, update, add, and remove properties with simple Python predicates and predefined tags.
  • One-call sanitize: strip every detected property before sharing a file.
  • Document inspection: detect format/MIME type, page count, encryption, digital signatures, comments, and hidden pages.
  • Export: dump the metadata tree to CSV, XLSX, JSON, or XML.
  • Cross-Platform: Windows x64/x86, Linux x64, macOS x64/ARM64.

Common Tasks

  • Detect a file's real format and MIME type by its internal structure
  • Read EXIF/XMP/IPTC properties from photos
  • Read and edit ID3/APE/Lyrics tags in audio files
  • Strip author, comments, and revision history from Office documents before publishing
  • Find and remove properties that match a condition (by tag, name, type, or value)
  • Export a document's full metadata tree to a spreadsheet for auditing
  • Feed extracted metadata into a search, compliance, or DAM pipeline

Supported File Formats

This API supports a broad set of document and media formats, including:

  • Word Processing: DOC, DOCX, DOCM, ODT, DOT, DOTM
  • Spreadsheets: XLS, XLSX, XLSM, ODS, XLSB, XLT
  • Presentations: PPT, PPTX, PPS, PPSX, POT, POTM
  • PDF: PDF
  • Images: JPG, PNG, TIFF, BMP, GIF, PSD
  • Audio/Video: MP3, WAV, OGG, AVI, MOV, MKV, ASF, FLV, MK3D
  • Email: EML, MSG
  • eBook: EPUB, MOBI, FB2
  • Archives: ZIP, RAR, 7Z, TAR, CB7, CBR
  • Fonts: OTF, TTF, TTC, OTC
  • CAD: DWG, DXF
  • 3D: FBX, STL, 3DS, DAE, GLTF
  • Visio: VSD, VSDX, VDX, VSS, VSX, VTX
  • OneNote: ONE
  • GIS: KML, GPX, GEOJSON, GML, OSM, SHP
  • Other formats: MPP, MPT, TORRENT, VCF, VCR

Supports 110+ file formats.

For a complete list, see supported formats.

Examples

Read metadata

from groupdocs.metadata import Metadata

with Metadata("input.docx") as metadata:
    for prop in metadata.find_properties(lambda p: True):
        print(f"{prop.name} = {prop.value}")

Get document info

from groupdocs.metadata import Metadata

with Metadata("input.xlsx") as metadata:
    info = metadata.get_document_info()
    print("Format:", info.file_type.file_format)
    print("MIME type:", info.file_type.mime_type)
    print("Pages:", info.page_count)
    print("Size:", info.size, "bytes")
    print("Encrypted:", info.is_encrypted)

Find properties by tag

from groupdocs.metadata import Metadata
from groupdocs.metadata.tagging import Tags

with Metadata("input.docx") as metadata:
    authors = metadata.find_properties(lambda p: Tags.person.creator in list(p.tags))
    for prop in authors:
        print(prop.name, "=", prop.value)

Set / update properties and save

from datetime import datetime
from groupdocs.metadata import Metadata
from groupdocs.metadata.common import PropertyValue
from groupdocs.metadata.tagging import Tags

with Metadata("input.docx") as metadata:
    affected = metadata.set_properties(
        lambda p: Tags.time.created in list(p.tags),
        PropertyValue(datetime.now()),
    )
    print("Updated:", affected)
    metadata.save("output.docx")

Remove all metadata (sanitize)

from groupdocs.metadata import Metadata

with Metadata("input.pdf") as metadata:
    removed = metadata.sanitize()
    print("Removed:", removed)
    metadata.save("clean.pdf")

Export the metadata tree

from groupdocs.metadata import Metadata
from groupdocs.metadata.export import ExportManager, ExportFormat

with Metadata("input.pdf") as metadata:
    properties = list(metadata.find_properties(lambda p: True))
    ExportManager(properties).export("metadata.xlsx", ExportFormat.XLSX)

Load from a stream

import io
from groupdocs.metadata import Metadata

with open("input.docx", "rb") as stream:
    with Metadata(stream) as metadata:
        print("Format:", metadata.file_format)

buf = io.BytesIO(downloaded_bytes)
with Metadata(buf) as metadata:
    print(metadata.get_document_info().file_type.file_format)

AI Agent & LLM Friendly

This package is designed for seamless integration with AI agents, LLMs, and automated code generation tools.

  • AGENTS.md in the package — AI coding assistants (Claude Code, Cursor, GitHub Copilot) auto-discover the API surface, usage patterns, and troubleshooting tips from the installed package
  • MCP server — connect your AI tool to GroupDocs documentation for on-demand API lookups:
    { "mcpServers": { "groupdocs-docs": { "url": "https://docs.groupdocs.com/mcp" } } }
    
  • Machine-readable docs — full documentation available as plain text for RAG and LLM context:
    • Single file: https://docs.groupdocs.com/metadata/python-net/llms-full.txt
    • Per page: append .md to any docs URL

Evaluation Mode

The API works without a license in evaluation mode, with these limitations:

  • Only the first few properties of each metadata package are read.
  • Saving files is disabledsave() raises an "Evaluation only" exception.

To remove these limitations, apply a license or request a temporary license:

from groupdocs.metadata import License
License().set_license("path/to/license.lic")

Or set the environment variable (auto-applied at import):

export GROUPDOCS_LIC_PATH="path/to/license.lic"

Troubleshooting

Issue Platform Fix
System.Drawing.Common is not supported Linux/macOS apt-get install libgdiplus (Linux) or brew install mono-libgdiplus (macOS)
The type initializer for 'Gdip' threw an exception macOS brew install mono-libgdiplus
Errors processing images that need fonts Linux apt-get install ttf-mscorefonts-installer fontconfig && fc-cache -f
DOTNET_SYSTEM_GLOBALIZATION_INVARIANT errors Linux Do NOT set this variable. ICU must be available.

System Requirements

  • Python 3.5 - 3.14
  • Windows x64/x86, Linux x64, macOS x64/ARM64

More Resources

Also available for other platforms: .NET | Java | Node.js


Product Page | Docs | Demos | API Reference | Blog | Free Support | Temporary License

Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

groupdocs_metadata_net-26.7.0-py3-none-win_amd64.whl (171.7 MB view details)

Uploaded Python 3Windows x86-64

groupdocs_metadata_net-26.7.0-py3-none-macosx_11_0_arm64.whl (170.7 MB view details)

Uploaded Python 3macOS 11.0+ ARM64

groupdocs_metadata_net-26.7.0-py3-none-macosx_10_14_x86_64.whl (172.9 MB view details)

Uploaded Python 3macOS 10.14+ x86-64

File details

Details for the file groupdocs_metadata_net-26.7.0-py3-none-win_amd64.whl.

File metadata

File hashes

Hashes for groupdocs_metadata_net-26.7.0-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 7efc6d4eb3e65ccce35b3218464046b009dada397f3ba32d1f52a04b9f63e24c
MD5 1681273223b9e93b4a0417e9e90e24d0
BLAKE2b-256 bc2427f95a7efcf1c7793d993ed67ad68261276630c18e0c55d26db8fa9e16a8

See more details on using hashes here.

File details

Details for the file groupdocs_metadata_net-26.7.0-py3-none-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for groupdocs_metadata_net-26.7.0-py3-none-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 865725129bd5ec41d24123afc46c68ab7562482645c4c0d4c16dcb70edeeb79a
MD5 e1c5a2dc2339dc76fb3f9ac86c1bd81c
BLAKE2b-256 eb2552e96fb64e1df12c980948d304a6aa7dc7bf751783930b1b266aec732adf

See more details on using hashes here.

File details

Details for the file groupdocs_metadata_net-26.7.0-py3-none-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for groupdocs_metadata_net-26.7.0-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ec61a38e3829b72337402c4a263172aba24cd3860ec2663b0a1c7646c804f8ab
MD5 47a7d8430c857fde29fdb012d89ba4e6
BLAKE2b-256 4be9a98a41fb397a4a66b42b595889422471db02cdd65cc52beaa0de82104107

See more details on using hashes here.

File details

Details for the file groupdocs_metadata_net-26.7.0-py3-none-macosx_10_14_x86_64.whl.

File metadata

File hashes

Hashes for groupdocs_metadata_net-26.7.0-py3-none-macosx_10_14_x86_64.whl
Algorithm Hash digest
SHA256 c3a229fa909d1ac399235ec80d501879f4bbd9170e791fb72bcecf2031e76920
MD5 9ab339ebd9b708b0a043d0b9821b5f68
BLAKE2b-256 037b018dcf16658cafe76e14846bdceb4886c043cbaf7e6a0aaa4bad8d830d11

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