docx Claude Code Skill
Claude Code SkillClaude CodeDocuments & Content CreationThe explanation below is AI-generated. Please verify it against the sources.
This is a Claude skill for creating, reading, editing, and otherwise manipulating Microsoft Word .docx and .dotx files. It covers generating new documents from scratch with the docx npm library, reading content from existing files via pandoc, and directly editing a document's internal XML when modifying an existing file. It also provides guidance for handling tracked changes, inserting comments, replacing or inserting images, and verifying rendered output by converting to PDF and then to page images. The skill is intended for deliverables like reports, memos, letters, and templates produced as Word files, and explicitly excludes PDFs, spreadsheets, Google Docs, and unrelated coding tasks.
What you can do with docx
- Generate new .docx files programmatically using the docx npm library, with guidance on page size, tables, lists, headings, and tables of contents
- Extract and read the text content of existing Word documents by converting them to markdown
- Edit an existing .docx by unpacking its XML, modifying the document content, and repacking it
- Convert legacy .doc files into .docx before editing
- Apply and validate tracked changes (insertions and deletions) with proper author and date attribution, and produce a clean version with all changes accepted
- Add and anchor comments to specific text ranges within a document
- Insert, replace, or reposition images inside a document
- Verify generated or edited documents by rendering them to PDF and page images for visual inspection
Sources
History of docx
- Claude Code Skill Updated skill content (SKILL.md) of docx
- Claude Code Skill Updated skill content (SKILL.md) of docx
- Claude Code Skill Updated license of docx (Proprietary. LICENSE.txt has complete terms → Complete terms in LICENSE.txt)
- Claude Code Skill Updated skill content (SKILL.md) of docx
- Claude Code Skill Updated the official description of docx