Skip to main content

A lightning-fast VCF contact extractor to CSV, TXT, JSON, HTML, SQLite, or terminal preview

Project description

vcfzap

vcfzap is a high-performance, feature-rich command-line tool that extracts contact information from VCF (vCard) files and exports it into multiple formats: CSV, TXT, JSON, HTML, SQLite, or a color-coded terminal preview. Whether you're a developer, sysadmin, or power user, vcfzap makes contact extraction seamless and efficient.


Total Downloads


✨ Key Features

  • 🚀 Multi-format Export: Convert .vcf files to CSV, TXT, JSON, HTML, or SQLite database.
  • 🧩 Field Selection: Choose exactly which fields to extract: name, phone, email, address, organization.
  • 🔍 Dry Run Mode: Simulate output without creating any files — perfect for testing.
  • 🌐 Encoding Detection: Automatically handles VCFs with different character encodings.
  • 🔐 Safe Overwriting: Built-in prompts to prevent accidental file overwrite and respect for permissions.
  • Performance-focused: Fast parsing with progress display — handles large files effortlessly.
  • Timestamp Support: Automatically append timestamps to output filenames.
  • 🧘 Automation-friendly: Flags like --no-color, --quiet, and --no-prompt are ideal for scripting and CI.
  • 💽 Rich Terminal Preview: View a beautiful table-rendered contact list directly in the terminal.
  • 🛠 Verbose Logging: Output logs to file and optionally enable debug mode for advanced insight.

⚙ Installation

📦 Install via PyPI

pip install vcfzap

🧬 Install from GitHub (latest)

git clone https://github.com/musaddiq/vcfzap.git
cd vcfzap
pip install .

🧪 Basic Usage

vcfzap <VCF_FILE> [OPTIONS]

✅ Examples

vcfzap contacts.vcf --preview --limit 5
vcfzap contacts.vcf --csv output.csv --timestamp
vcfzap contacts.vcf --json contacts.json --fields name,phone,email --pretty-json
vcfzap contacts.vcf --html contacts.html --fields email
vcfzap contacts.vcf --sqlite contacts.db --no-prompt
vcfzap --check-dependencies

⚙ Options & Arguments

📅 Input

  • vcf_file (positional): Path to your .vcf file.

🎯 Output Formats (choose one)

  • --csv <file>: Export to CSV file
  • --txt <file>: Export to plain text file
  • --json <file>: Export to JSON file
  • --html <file>: Export to styled HTML table
  • --sqlite <file>: Export to SQLite database
  • --preview: Show contacts in a color-coded terminal table (no file output)

🎛 Behavior & Customization

  • --fields name,phone,email: Comma-separated list of fields to extract
  • --limit N: Limit number of contacts
  • --timestamp: Add current timestamp to output filename
  • --max-size N: Warn if file is larger than N MB
  • --detect-encoding: Automatically detect file encoding
  • --csv-delimiter ";": Set custom delimiter for CSV export
  • --log-file <file>: Save detailed logs to specified file
  • --no-color: Disable colored CLI output
  • --quiet: Suppress non-essential messages
  • --no-logs: Disable logging entirely
  • --no-prompt: Disable all interactive prompts (force overwrite, large file warning)
  • --pretty-json: Enable human-readable indented JSON
  • --check-dependencies: Check for any missing Python dependencies
  • -v, --version: Show version information

🌐 Field Reference

Field Description
name Full name (e.g., John Doe)
phone Phone numbers with optional extensions
email Email addresses
address Full physical address
organization Company or organization name

📦 Output Format Overview

Format Description
CSV Clean spreadsheet with optional delimiter
TXT Readable text with labeled fields
JSON Compact or pretty-printed structure
HTML Styled responsive HTML table
SQLite Structured database with dynamic schema
Preview Terminal-based color table preview only

❗ Notes

  • Only one output format can be specified per command.
  • Use --dry-run to verify before exporting.
  • Ideal for automation pipelines via --no-prompt, --quiet, and --log-file.

🧑‍💻 Advanced Usage

vcfzap mycontacts.vcf \
  --csv contacts.csv \
  --fields name,email,address \
  --timestamp \
  --detect-encoding \
  --log-file logs/vcfzap.log \
  --quiet

🛡 License

MIT License

👨‍💻 Author

Crafted with intent by Mallik Mohammad Musaddiq 📧 musaddiqmalik@gmail.com 🔗 GitHub Repo


🔍 Like vcfzap?

If this tool made your workflow easier, consider ⭐️ starring the repository or sharing it with others in need. * 📧 musaddiqmalik@gmail.com 🔗 GitHub Repo


🔍 Like vcfzap?

If this tool made your workflow easier, consider ⭐️ starring the repository or sharing it with others in need.

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

vcfzap-1.2.0.tar.gz (20.3 kB view details)

Uploaded Source

Built Distribution

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

vcfzap-1.2.0-py3-none-any.whl (17.8 kB view details)

Uploaded Python 3

File details

Details for the file vcfzap-1.2.0.tar.gz.

File metadata

  • Download URL: vcfzap-1.2.0.tar.gz
  • Upload date:
  • Size: 20.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.11

File hashes

Hashes for vcfzap-1.2.0.tar.gz
Algorithm Hash digest
SHA256 1f69e80f48bbbe42552adf84bbae05ae2a1505d63801863136e9854404e28a5e
MD5 2ed74e1d3df5176b1d54e39e5b09c53d
BLAKE2b-256 7ecd4ba15eb688010932190aeca47374290e88b55b08ee746561a28d979c905b

See more details on using hashes here.

File details

Details for the file vcfzap-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: vcfzap-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 17.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.11

File hashes

Hashes for vcfzap-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4d4fc9af3412d5a267c21df51a4aed43e9b40285b83d6afc404d77e094ebbfaf
MD5 537c8a1e62f371d2ba64822a04abf838
BLAKE2b-256 b4add865fa71c9fad22f75a8723831866a070cd9837385ee26f8c70763f71d77

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