Installation
Overview
Aspose.Words FOSS for Java is published on Maven Central. Add it as a dependency and your build tool downloads it together with the libraries it needs.
Prerequisites
| Requirement | Detail |
|---|---|
| Java | 8 or later. The library was run on Java 8, 17 and 21 for this documentation. |
| Build tool | Maven (used for this documentation), or any tool that can put jars on the class path. |
| Operating system | Any operating system that runs Java. |
| Word | Not needed. The library reads and writes documents itself. |
Step 1: Add the Dependency
Add the package to your build:
<dependency>
<groupId>org.aspose</groupId>
<artifactId>aspose-words-foss</artifactId>
<version>26.3.0</version>
</dependency>Maven also downloads the ten ordinary libraries the package depends on: stax2-api, seven TwelveMonkeys image libraries (common-lang, common-io, common-image, imageio-core, imageio-metadata, imageio-tiff, imageio-webp), webp-imageio and pngencoder. Two modified libraries, a Woodstox XML parser and a Bouncy Castle FIPS jar, are already inside the package, so you do not add them yourself.
Step 2: Use the Jar Without a Build Tool
Each release on GitHub also carries the jar, its sources and javadoc jars, their signatures, and a checksum file named SHA256SUMS. The jar on GitHub is the same file as the one on Maven Central. It does not include the ten libraries above, so put them on the class path as well.
Step 3: Check the Installation
Build the example in Quick Start. If it compiles and writes a file named Hello.docx, the package and its dependencies are in place. The example then opens Report.docx, which must exist in the directory the program runs in; without it the program stops with a FileNotFoundException after Hello.docx has been written.