{"id":13459192,"url":"https://github.com/open-xml-templating/docxtemplater","last_synced_at":"2026-04-06T06:04:07.093Z","repository":{"id":8492206,"uuid":"10098528","full_name":"open-xml-templating/docxtemplater","owner":"open-xml-templating","description":"Generate docx, pptx, and xlsx from templates (Word, Powerpoint and Excel documents), from Node.js or the browser. Demo: https://www.docxtemplater.com/demo. #docx #office #generator #templating #report #json #generate #generation #template #create #pptx #docx #xlsx #react #vuejs #angularjs #browser #typescript #image #html #table #chart","archived":false,"fork":false,"pushed_at":"2024-10-10T13:56:36.000Z","size":27614,"stargazers_count":3033,"open_issues_count":7,"forks_count":349,"subscribers_count":83,"default_branch":"master","last_synced_at":"2024-10-15T01:05:24.825Z","etag":null,"topics":["docx","docx-generation","docx-generator","docx-template","excel","javascript","microsoft","office","powerpoint","pptx","template","word","xlsx"],"latest_commit_sha":null,"homepage":"https://www.docxtemplater.com","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/open-xml-templating.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":".github/contributing.md","funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2013-05-16T09:59:54.000Z","updated_at":"2024-10-15T00:45:45.000Z","dependencies_parsed_at":"2023-01-13T15:01:01.554Z","dependency_job_id":"626b3531-1463-41e9-bf81-16d027d6d902","html_url":"https://github.com/open-xml-templating/docxtemplater","commit_stats":{"total_commits":2322,"total_committers":36,"mean_commits":64.5,"dds":"0.025409130060292884","last_synced_commit":"9f4a3c382ba18f2e958d6bbaffda0fb8acc4f052"},"previous_names":["edi9999/docxtemplater"],"tags_count":318,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-xml-templating%2Fdocxtemplater","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-xml-templating%2Fdocxtemplater/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-xml-templating%2Fdocxtemplater/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-xml-templating%2Fdocxtemplater/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/open-xml-templating","download_url":"https://codeload.github.com/open-xml-templating/docxtemplater/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245308610,"owners_count":20594275,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docx","docx-generation","docx-generator","docx-template","excel","javascript","microsoft","office","powerpoint","pptx","template","word","xlsx"],"created_at":"2024-07-31T09:01:09.631Z","updated_at":"2025-12-15T04:25:32.020Z","avatar_url":"https://github.com/open-xml-templating.png","language":"JavaScript","readme":"# docxtemplater\n\n[![Download count](https://img.shields.io/npm/dm/docxtemplater.svg?style=flat)](https://www.npmjs.org/package/docxtemplater) [![Current tag](https://img.shields.io/npm/v/docxtemplater.svg?style=flat)](https://www.npmjs.org/package/docxtemplater) [![CDNJS version](https://img.shields.io/cdnjs/v/docxtemplater.svg)](https://cdnjs.com/libraries/docxtemplater) [![size](http://img.badgesize.io/https://raw.githubusercontent.com/open-xml-templating/docxtemplater-build/master/build/docxtemplater-latest.min.js?label=size\u0026style=flat-square)](https://raw.githubusercontent.com/open-xml-templating/docxtemplater-build/master/build/docxtemplater-latest.min.js) [![gzip size](http://img.badgesize.io/https://raw.githubusercontent.com/open-xml-templating/docxtemplater-build/master/build/docxtemplater-latest.min.js?compression=gzip\u0026label=gzip%20size\u0026style=flat-square)](https://raw.githubusercontent.com/open-xml-templating/docxtemplater-build/master/build/docxtemplater-latest.min.js)\n\n**docxtemplater** is a library to generate docx/pptx documents from a docx/pptx template. It can replace {placeholders} with data and also supports loops and conditions. The templates can be edited by non-programmers, for example your clients.\n\n**docxtemplater** is very robust because of the many fixed issues over the years, and the high quality of tests and code.\n\n## Features\n\n[Demo Site](https://docxtemplater.com/demo)\n\n- \u003ca href=\"https://docxtemplater.com/demo#simple\"\u003eReplace a {placeholder} by a value\u003c/a\u003e\n- \u003ca href=\"https://docxtemplater.com/demo#loops\"\u003eUse loops: {#users} {name} {/users} \u003c/a\u003e\n- \u003ca href=\"https://docxtemplater.com/demo#loop-table\"\u003eUse loops in tables to generate columns\u003c/a\u003e\n- \u003ca href=\"https://docxtemplater.com/demo#conditions\"\u003eUse conditions (if users.length\u003e3) with angular Parsing\u003c/a\u003e\n- \u003ca href=\"https://docxtemplater.com/demo#xml-insertion\"\u003eInsert custom XML {@rawXml} (for formatted text for example)\u003c/a\u003e\n\n## Quickstart\n\n- [Get started with docxtemplater on nodejs](https://docxtemplater.com/docs/get-started-node)\n- [Get started with docxtemplater in the browser (react, angular, vue, nextjs)](https://docxtemplater.com/docs/get-started-browser)\n\n## Documentation\n\nThe full documentation of the latest version can be found [here](https://docxtemplater.com/docs).\n\nSee [CHANGELOG.md](CHANGELOG.md) for information about how to migrate from older versions.\n\n## Modules\n\nFunctionality can be added with the following paid modules :\n\n- [Image module](https://docxtemplater.com/modules/image/) to add a given image with the syntax: `{%image}`;\n- [Html Module](https://docxtemplater.com/modules/html/) to insert formatted text in a docx document with the syntax `{~html}`;\n- [XLSX Module](https://docxtemplater.com/modules/xlsx) to be able to do templating on Excel files (xlsx extension), also with loops and conditions;\n- [Chart Module](https://docxtemplater.com/modules/chart/) to replace a chart by using data from the JSON object that you give with the syntax `{$chart}`;\n- [Html-Pptx Module](https://docxtemplater.com/modules/html-pptx/) to insert formatted text in a pptx document with the syntax `{~html}`;\n- [Error Location Module](https://docxtemplater.com/modules/error-location) to show the errors in the template using Word comments\n- [Slides Module](https://docxtemplater.com/modules/slides/) to create multiple slides dynamically with the syntax `{:users}`;\n- [Subtemplate Module](https://docxtemplater.com/modules/subtemplate) to include an external docx file inside a given docx file with the syntax `{:include doc}`;\n- [Subsection Module](https://docxtemplater.com/modules/subsection) to include subsections (headers/footers) from an other document with the syntax `{:subsection doc}`;\n- [Subtemplate-pptx Module](https://docxtemplater.com/modules/pptx-sub/) to include an external pptx file inside a given pptx file with the syntax `{:include doc}`;\n- [Word-Run Module](https://docxtemplater.com/modules/word-run) to include raw runs (\u003cw:r\u003e) inside the document with the syntax `{r@wrun}`. This makes it possible to include styled text without having to remove the enclosing paragraph like in the {@rawXml} tag;\n- [QrCode Module](https://docxtemplater.com/modules/qrcode) to replace an image, keeping any existing properties;\n- [Table Module](https://docxtemplater.com/modules/table) to create tables from two dimensional data using the syntax `{:table data}`;\n- [Meta Module](https://docxtemplater.com/modules/meta) to make a document readonly, add a text watermark or update the margins;\n- [Styling Module](https://docxtemplater.com/modules/styling) restyle a paragraph, a cell or a table depending on some data using the syntax `{:stylepar style}`;\n- [Footnotes Module](https://docxtemplater.com/modules/footnotes) to be able to add footnotes to a document using the syntax `{:footnotes foot}`\n- [Paragraph Placeholder Module](https://docxtemplater.com/modules/paragraph-placeholder) to simplify conditions that should show or hide a given paragraph using the syntax `{?tag}`\n\n## About docxtemplater\n\nDocxtemplater is my main job, and has been maintained for over 8 years. Expect to get great support if you buy any modules, and also good support on the open-source version.\n","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopen-xml-templating%2Fdocxtemplater","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopen-xml-templating%2Fdocxtemplater","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopen-xml-templating%2Fdocxtemplater/lists"}