Module · Regira.Office.Word

Word in .NET.
Templates, not string building.

A .docx someone made in Word stays the design; your code supplies the values. Placeholders take single values, collection parameters fill repeating table rows, and the same service converts the result to PDF.

← All Office modules

§ 01The contract

What every provider gives you.

The interfaces below are the part that does not change when you swap the library underneath. Each provider then adds whatever extras its own library exposes.

01

Template + parameters

WordTemplateInput carries the document and two dictionaries: one for single values, one for collections that expand into table rows.

02

Convert

Convert a generated document to PDF or another format through the same service — no second library for the signing copy.

03

Merge

Append an addendum, a set of terms or a cover page by merging several template inputs into one document.

04

Extract

Pull plain text or embedded images back out, for indexing or for migrating content off old documents.

Interfaces
IWordServiceIWordCreatorIWordConverterIWordMergerIWordTextExtractorIWordImageExtractor
§ 02Providers

5 published implementations.

Install the one that fits your runtime and licensing, and name it once at registration. Every package here is published on nuget.org.

AsposeGotenbergMiniWordSpireSyncfusion
§ 03In code

Inject the interface. Name the provider once.

The provider appears where the concrete class is constructed, and nowhere else. Always-current samples live in the package documentation.

Fill a template, then convert to PDFC#
// A .docx template plus values. Collection parameters fill repeating table rows.
IWordService word = new Regira.Office.Word.Spire.WordManager();

IMemoryFile contract = await word.Create(new WordTemplateInput
{
    Template         = template,
    GlobalParameters = new Dictionary<string, object>
    {
        ["ClientName"] = client.Name,
        ["StartDate"]  = start.ToString("d")
    }
});

// Same service converts and merges.
IMemoryFile pdf = await word.Convert(new WordTemplateInput { Template = contract }, FileFormat.Pdf);
§ 04Without .NET

The same thing, over HTTP.

Create a Word document from a template, extract plain text, merge documents and convert between DOCX and PDF over HTTP.

Call it from any language.

The free tier needs no key and is rate-limited to 5 requests / 60 s. A trial or commercial key removes the limit — send it in the X-License-Key header.

Also explore

PDF

Generate PDFs from HTML, merge and split them, extract text and render pages as images — over DocNET, SelectPdf, Spire, Playwright or PuppeteerSharp.