# plutext/docx4j

JAXB-based Java library for Word docx, Powerpoint pptx, and Excel xlsx files

Repository: https://github.com/plutext/docx4j
Canonical: https://ross.abutalabs.com/products/docx4j
Homepage: https://www.docx4java.org/
Language: Java
License Family: other
Last push: 2026-08-26T10:10:22+00:00

## Health v2 (maintenance only)
Score: 77/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 99, release rhythm 35, longevity 100
- inputs: {"age_days": 5227, "days_push": 7, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases, no_license
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2380, forks 1231 (observed 2026-08-28T04:06:42.282683+00:00)

## What it is
docx4j is an open-source (Apache v2) Java library for creating, editing, and saving Microsoft OpenXML packages, including Word docx, PowerPoint pptx, and Excel xlsx files, using JAXB for the in-memory object representation. It offers power at the file-format level: document generation via data binding or MERGEFIELD, CustomXML binding, transforms, and export to HTML or PDF.

## Use cases
- generate word documents from templates in java
- read and edit docx files programmatically
- convert docx to pdf in java
- mail merge into docx templates with MERGEFIELD or content controls
- create or modify powerpoint pptx presentations from java
- manipulate excel xlsx workbooks from java
- export word documents to html

## When to choose
- You need format-level control over OpenXML documents from Java - anything the file format supports can be done
- You need document generation via variable binding, content controls, or MERGEFIELD with repeats and conditionals
- You need docx-to-PDF or docx-to-HTML export without driving a full Office installation
- You are on Java 11+ and want an actively maintained OpenXML library with JPMS modularised releases

## When to avoid
- You are not on the JVM - this is a Java library, similar to Microsoft's OpenXML SDK but for Java
- You want a simple high-level API and are unwilling to learn JAXB and the Open XML file structure
- You are stuck on legacy Java 8 - docx4j-8 is unsupported
- You need only trivial text extraction where a lighter-weight parser would suffice

## Facets
- artifact type: library
- maturity: active
- function: parser, templating, pdf
- domain: files, pdf, developer-tools, spreadsheets
- platform: jvm, cross-platform
- tags: docx, pptx, xlsx, openxml, ooxml, jaxb, word, powerpoint, excel, document-generation, mail-merge, java, html-export, office-documents

## Member repositories
- plutext/docx4j (main) score 77

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:06:42.282683+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T02:34:52.349668+00:00, confidence not recorded.
  - readme: https://github.com/plutext/docx4j (fetched 2026-08-28T04:06:42.282683+00:00, sha 47fe6ecc3830)
  - homepage: https://www.docx4java.org/ (fetched 2026-08-29T10:15:45.304888+00:00, sha 5e6347ff6fc9)
- Data as of 2026-08-30T08:39:29.467469+00:00.
