Welcome to WUIC documentation page

Getting started

This documentation gathers all information you need to use Web UI Compressor, the web assets optimizers for the JVM. Before going deeper, you may take a look at the website index for a general introduction ;-) Also browse the Features and the FAQ below.

Find the documentation for following purpose:


  • Cache optimization:

    • HTTP header to cache to the client version URLs of the resources

    • Server side caching (built-in memory cache or EhCache support)

    • HTML5 cache manifest support for the entire page

  • Network optimization:

    • Support HTTP/2 server-push for Java server

    • Support resource-hint specification

  • Content optimizations:

    • GZIP content when browser accepts it

    • Aggregate scripts (JS and CSS)

    • Aggregate images with a bin packing algorithm and compute sprites for each of them

    • Minify JS and CSS thanks to YUICompressor

    • Minify HTML thanks to html-compressor

    • Inline resources (JS and CSS)

    • Extracts inline scripts from HTML pages

  • Hot reload:

    • Polls configuration files to reload changes

    • Evict cache entries if necessary

  • API:

    • JSP tag support

    • Thymeleaf processor support

    • Built-in tag support

  • Configuration:

    • Organize the resources easily, declare their location and how to process them

    • Completely configurable API in web.xml, dedicated XML or property file

    • Possible to configure in pure Java

    • Conventions over configuration with default settings and auto-configuration

  • Process at build time:

    • Maven plugin

    • Ant task

  • Process at runtime:

    • Servlet that serves optimized content

    • Filter that optimizes HTML content of the fly

    • ContextListener that bootstraps WUIC automatically

    • Asynchronous processing with Servlet 3 support

    • Best-effort: don’t deliver content if not ready yet

    • Process and cache the result when server starts

  • Additional frameworks and language:

    • Support Spring Framework asset pipeline

    • Support Typescript compilation with Node.JS integration or embedded Trireme

  • Maven:

    • Modular extensions with a lot of artifacts under Maven Central

    • Automatically enables extensions when discovered in classpath

  • Versioned URLs:

    • Fixed version number in properties

    • Version number computed from file’s modification date

    • Version number computed from CRC32 file checksum

  • Resource resolution:

    • Abstraction of the protocol to use (Classpath, File System, Webapp, HTTP(s), FTP(s), SFTP, Cloud, etc)

    • Support wildcard for resource resolution

    • Support pure regex for resource resolution

  • Discover nested resources URLs, rewrite them and optimize their content:

    • CSS: resolve URLs in @font-face, background url and @import

    • JS: resolve templateUrl for AngularJS and sourceMappingURL for sourcemaps.

    • HTML: resolve inline JS and CSS content, <img>, <script> and <link> tags


Please find our FAQ section here.


The project is under MIT license which could be found here.

Moreover, WUIC directly embeds components from projects under Apache 2.0 license:



WUIC comes with different samples. Reading them is a good way to discover the advantages and the simplicity of WUIC.


All the JARs are managed with maven and could be downloaded manually from the central repository.

Source code

Source code is hosted on github. The source code of our official release is on the MASTER branch with a ZIP archive downloadable here. You should be also interested in the current state of our work for the next release. Download the ZIP archive of the SNAPSHOT branch here.

Optimize webapp performances

Step-by-step 5 minutes tutorials

If you want to see WUIC directly in action and play with it, you can directly jump into our step-by-step 5 minutes tutorials. You can also see several samples here.

Going deeper

If you want to go deeper, you can read our set of articles describing all the implemented concepts. You can start by the design page and reading at least the General architecture and terminology section.

Then, follow the step-by-step tutorials that illustrate how you can start very quickly with automatic optimizations and then gradually enable more WUIC features to capitalize on all offered possibilities:

  • Configure WUIC to serve your statics from your servlet container and install the servlet filter that optimize your HTML page

  • Enable automatically extensions just by adding dependencies

  • Generate your scripts imports statements in your HTML page thanks to JSP or Thymeleaf support

  • Manage your statics with XML configuration file

  • Process your raw statics at runtime

More tutorials

WUIC provides extension to support several frameworks and languages like NodeJS, Spring, AngularJS or Typescript. You will find more tutorials about that here.

Finally, more advanced tutorials can be found here.


After this, you’ll find below the detailed documentation about different components browsed in the tutorials.

Available engines and DAO


You will find the javadoc of the current snapshot regularly updated here.

How to extend WUIC

WUIC is designed to be extended easily. You will find a complete advanced tutorial here.

How to use WUIC in my framework

If you want to build a part of your framework on top of WUIC, you don’t have to ask your users to use XML configuration file. You can totally hide this configuration point by using Java Config.

Then you will find implementation details directly in the javadoc.