HTML Webpack Plugin is a webpack plugin that simplifies creation of HTML files to serve your webpack bundles.
The tool solves the problem of managing HTML entry points when webpack bundles include hashes in filenames that change with every compilation. Rather than manually updating HTML files to reference new bundle names, the plugin automatically generates HTML files or processes templates to inject the correct bundle references. It supports three approaches: letting the plugin generate a minimal HTML file, supplying a custom template using lodash template syntax, or providing your own loader for complete control.
The plugin requires no configuration to work and integrates into webpack projects of any size. It suits any webpack-based application that needs to serve bundles through HTML files, from simple single-page applications to complex multi-entry setups. The tool works with both webpack 4 and webpack 5, with separate installation paths for each version.
The project maintains active sponsorship support and provides a hooks system that allows other plugins to extend its functionality with zero additional configuration needed for integration.