Skip to main content

A simple tool to replace placeholders and base64 images in Word .docx templates

Project description

📝 json2docx

json2docx is a Python library that fills Word .docx templates using a dictionary of values.
It replaces text placeholders and base64-encoded images (matched via alt text) recursively in paragraphs and tables.


✅ Features

  • 🔤 Replace text placeholders like {{key}}
  • 🖼 Replace images using base64 data matched by image Alt Text
  • 🔁 Works recursively inside tables, rows, and cells
  • 📄 Supports both .docx paragraphs and tables
  • 🪄 Easy to integrate in automation and document generation workflows

📦 Installation

pip install json2docx

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

json2docx-0.1.3.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

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

json2docx-0.1.3-py3-none-any.whl (3.3 kB view details)

Uploaded Python 3

File details

Details for the file json2docx-0.1.3.tar.gz.

File metadata

  • Download URL: json2docx-0.1.3.tar.gz
  • Upload date:
  • Size: 3.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for json2docx-0.1.3.tar.gz
Algorithm Hash digest
SHA256 19732c8a9010e9b6347d0faea5d4918ad73857be0a0e9d69920894cc3f07882c
MD5 cfd432fc2a96e170ed641809bfd7cbe9
BLAKE2b-256 7038d4904d35dfe27b752b58e548c8042c4780715cd67df2e83accd654501ccb

See more details on using hashes here.

File details

Details for the file json2docx-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: json2docx-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 3.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for json2docx-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 749e82d59e5adafe9dd0180a62cecafaa3e608d401c1b68e329feda898fb26e6
MD5 23a7b772f5673d3db39d1d053ca7e849
BLAKE2b-256 d71895ce8d42bfe930f82fe7924955902951e57c6ccc4f0f667228ae32442e03

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