A powerful, cross-platform Python tool for deep metadata extraction from various file types. Supports JSON, CSV, and log output with multi-threading. Perfect for digital forensics, organization, and curiosity!
- 🔍 Deep Metadata Extraction - Supports images (EXIF, GPS), audio (ID3), video, and documents
- 📁 Recursive Scanning - Explores entire directory structures
- 📊 Detailed Reports - Generates metadata logs, JSON, or CSV reports
- 🚀 Cross-Platform - Works on Windows, macOS, and Linux
- 🛡️ Error Resilient - Continues scanning even if some files fail
- 📈 Smart Filtering - Automatically skips system files and directories
- ⚡ Multi-Threading - Faster scans with parallel processing
- 🎯 Type Filtering - Scan only images, audio, video, or documents
- 🧭 GPS Conversion - Converts GPS coordinates to decimal degrees
- 📏 Human-Readable - File sizes and durations in readable format
| Category | Formats | Metadata Extracted |
|---|---|---|
| Images | JPG, PNG, HEIC, TIFF, WebP, BMP, GIF | EXIF, GPS, Dimensions, DPI, Camera settings |
| Audio | MP3, FLAC, M4A, OGG, WAV, AAC, Opus, WMA | ID3 tags, Duration, Bitrate, Sample rate |
| Video | MP4, MOV, AVI, MKV, WMV, FLV, WebM | Duration, Resolution, Codec, Framerate |
| Documents | PDF, DOCX, XLSX | Author, Pages, Title, Created/Modified dates |
| RAW | CR2, CR3, NEF, ARW, DNG, ORF, RW2, RAF | EXIF metadata via exifread |
| All Files | Any file type | Size, MIME type, Creation/modification dates |
-
Clone the repository:
git clone https://github.com/Shega-PT/metadata-explorer.git cd metadata-explorer -
Install dependencies:
pip install -r requirements.txt
No arguments — scans the files/ subfolder if it exists and has content; otherwise prompts for a path:
python universal.pyNo 'files/' subfolder found. Enter directory path to scan (or 'q' to quit):
Place your files in a files/ folder and run without arguments:
mkdir -p files
cp ~/photo.jpg files/
python universal.pyScan a specific directory explicitly:
python universal.py /path/to/your/filesScan your entire pictures folder:
python universal.py ~/PicturesJSON output:
python universal.py files --format jsonCSV output:
python universal.py files --format csv -o report.csvFilter by file type:
python universal.py files --type imagesWith progress bar and 4 threads:
python universal.py files --progress --threads 4Dry-run (list files only):
python universal.py files --dry-run| Flag | Description | Default |
|---|---|---|
directory |
Directory to scan | files/ subfolder, or prompts interactively |
-o, --output |
Output file path | metadata_report.{format} |
-f, --format |
Output format: log, json, csv |
log |
-t, --type |
File type filter: all, images, audio, video, documents |
all |
--dry-run |
List files without extracting metadata | off |
-p, --progress |
Show progress bar | off |
-n, --threads |
Number of worker threads (0 = auto) | 1 |
-v, --verbose |
Debug output | off |
============================================================
DIRECTORY: Vacation_Photos
============================================================
FILE: beach_sunset.jpg
PATH: Vacation_Photos/beach_sunset.jpg
METADATA:
• IMG_Format: JPEG
• IMG_Dimensions: 1920x1080
• IMG_EXIF_DateTimeOriginal: 2023:07:15 18:32:45
• IMG_GPS_LatitudeDecimal: 38.723167
• IMG_GPS_LongitudeDecimal: -9.154830
• IMG_Image_Make: Canon
• IMG_Image_Model: Canon EOS R5
• FILE_Size: 8.06 MB
• FILE_MimeType: image/jpeg
• FILE_Created: 2023-07-15T18:32:45
Edit the ignored_dirs and ignored_files sets in the FileManager class to customize what gets skipped.
The script defaults to metadata_report.log. Use --format json for JSON or --format csv for CSV output.
Use the UniversalMetadataExtractor class independently in your projects:
from pathlib import Path
from universal import UniversalMetadataExtractor
extractor = UniversalMetadataExtractor()
metadata = extractor.get_all_metadata(Path("your_file.jpg"))
print(metadata.get("IMG_EXIF_DateTimeOriginal"))metadata-explorer/
├── universal.py # Main script
├── requirements.txt # Dependencies
├── README.md # This file
├── LICENSE # GNU GPLv3 license
├── __init__.py # Package init
├── metadata_report.log # Generated report (example)
└── files/ # Default input folder (auto-scanned)
Contributions are welcome! Here's how you can help:
- Report Bugs - Open an issue with detailed information
- Suggest Features - Share your ideas for improvements
- Submit Pull Requests - Add support for new file formats or features
Clone and install in development mode:
git clone https://github.com/Shega-PT/metadata-explorer.git
cd metadata-explorer
pip install -e .
pip install -r requirements-dev.txt # Optional dev dependenciesMetadata Explorer v2 — Copyright (C) 2026 ShegaPT
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the LICENSE file for details.
- exifread for EXIF data extraction
- mutagen for audio metadata
- hachoir for video metadata analysis
- pymediainfo for detailed video metadata
- Pillow for image processing capabilities
- pillow-heif for HEIC/HEIF image support
- python-magic for MIME type detection
- pypdf for PDF metadata
- python-docx for DOCX metadata
- openpyxl for XLSX metadata
- tqdm for progress bar
This tool is for educational and organizational purposes only. Always respect privacy laws and obtain proper permissions before scanning others' files.
Made with ❤️ for digital explorers everywhere ⭐ If you find this useful, please consider starring the repository!