Java : Create XLS/XLSX file with Apache POI

You can use Apache POI HSSF to create an XLS file or Apache POI XSSF for an XLSX file.