A minimal, zero-dependency .NET library for generating PDF documents from text and Excel files.
$ dotnet add package MiniPdfA minimal, zero-dependency .NET library for converting Excel (.xlsx) files to PDF.
.xlsx files to paginated PDF with automatic column layoutdotnet add package MiniPdfusing MiniSoftware;
// File to file
MiniPdf.ConvertToPdf("data.xlsx", "data.pdf");
// File to byte array
byte[] pdfBytes = MiniPdf.ConvertToPdf("data.xlsx");
// Stream to byte array
using var stream = File.OpenRead("data.xlsx");
byte[] pdfBytes = MiniPdf.ConvertToPdf(stream);MiniPdf output is compared against LibreOffice as the reference renderer across 90 classic test cases (including 30 image-embedding cases).
| Category | Count | Threshold |
|---|---|---|
| 🟢 Excellent | 82 | ≥ 90% |
| 🟡 Acceptable | 7 | 70% – 90% |
| 🔴 Needs Improvement | 1 | < 70% |
Average overall score: 96.4% (text similarity 40% + visual similarity 40% + page count 20%)
All 90 test cases comparing MiniPdf output vs LibreOffice reference. Page 1 shown for multi-page results.
| MiniPdf | LibreOffice (Reference) |
|---|---|
| classic01 | Basic table with headers 🟢 99.7% |
![]() | ![]() |
| classic02 | Multiple worksheets 🟢 99.7% |
![]() | ![]() |
| classic03 | Empty workbook 🟢 100.0% |
![]() | ![]() |
| classic04 | Single cell 🟢 100.0% |
![]() | ![]() |
| classic05 | Wide table 🟢 99.5% |
![]() | ![]() |
| classic06 | Tall table 🟢 97.2% |
![]() | ![]() |
| classic07 | Numbers only 🟢 99.9% |
![]() | ![]() |
| classic08 | Mixed text and numbers 🟢 99.8% |
![]() | ![]() |
| classic09 | Long text 🔴 50.5% |
![]() | ![]() |
| classic10 | Special xml characters 🟢 99.8% |
![]() | ![]() |
| classic11 | Sparse rows 🟢 100.0% |
![]() | ![]() |
| classic12 | Sparse columns 🟢 99.9% |
![]() | ![]() |
| classic13 | Date strings 🟢 97.6% |
![]() | ![]() |
| classic14 | Decimal numbers 🟢 99.8% |
![]() | ![]() |
| classic15 | Negative numbers 🟢 99.8% |
![]() | ![]() |
| classic16 | Percentage strings 🟢 99.7% |
![]() | ![]() |
| classic17 | Currency strings 🟢 98.3% |
![]() | ![]() |
| classic18 | Large dataset 🟢 94.7% |
![]() | ![]() |
| classic19 | Single column list 🟢 99.8% |
![]() | ![]() |
| classic20 | All empty cells 🟢 100.0% |
![]() | ![]() |
| classic21 | Header only 🟢 100.0% |
![]() | ![]() |
| classic22 | Long sheet name 🟢 99.9% |
![]() | ![]() |
| classic23 | Unicode text 🟢 91.8% |
![]() | ![]() |
| classic24 | Red text 🟢 99.7% |
![]() | ![]() |
| classic25 | Multiple colors 🟢 99.5% |
![]() | ![]() |
| classic26 | Inline strings 🟢 99.9% |
![]() | ![]() |
| classic27 | Single row 🟢 99.9% |
![]() | ![]() |
| classic28 | Duplicate values 🟢 99.7% |
![]() | ![]() |
| classic29 | Formula results 🟢 99.7% |
![]() | ![]() |
| classic30 | Mixed empty and filled sheets 🟢 99.9% |
![]() | ![]() |
| classic31 | Bold header row 🟢 99.4% |
![]() | ![]() |
| classic32 | Right aligned numbers 🟢 99.8% |
![]() | ![]() |
| classic33 | Centered text 🟢 99.9% |
![]() | ![]() |
| classic34 | Explicit column widths 🟢 99.7% |
![]() | ![]() |
| classic35 | Explicit row heights 🟢 98.4% |
![]() | ![]() |
| classic36 | Merged cells 🟢 98.2% |
![]() | ![]() |
| classic37 | Freeze panes 🟢 99.3% |
![]() | ![]() |
| classic38 | Hyperlink cell 🟢 99.8% |
![]() | ![]() |
| classic39 | Financial table 🟢 99.5% |
![]() | ![]() |
| classic40 | Scientific notation 🟢 95.5% |
![]() | ![]() |
| classic41 | Integer vs float 🟢 97.5% |
![]() | ![]() |
| classic42 | Boolean values 🟢 99.4% |
![]() | ![]() |
| classic43 | Inventory report 🟢 99.0% |
![]() | ![]() |
| classic44 | Employee roster 🟢 97.4% |
![]() | ![]() |
| classic45 | Sales by region 🟢 99.8% |
![]() | ![]() |
| classic46 | Grade book 🟢 99.4% |
![]() | ![]() |
| classic47 | Time series 🟢 98.9% |
![]() | ![]() |
| classic48 | Survey results 🟢 98.7% |
![]() | ![]() |
| classic49 | Contact list 🟢 95.0% |
![]() | ![]() |
| classic50 | Budget vs actuals 🟢 99.1% |
![]() | ![]() |
| classic51 | Product catalog 🟢 98.1% |
![]() | ![]() |
| classic52 | Pivot summary 🟢 99.0% |
![]() | ![]() |
| classic53 | Invoice 🟢 99.3% |
![]() | ![]() |
| classic54 | Multi level header 🟢 99.2% |
![]() | ![]() |
| classic55 | Error values 🟢 99.5% |
![]() | ![]() |
| classic56 | Alternating row colors 🟡 88.6% |
![]() | ![]() |
| classic57 | Cjk only 🟡 85.2% |
![]() | ![]() |
| classic58 | Mixed numeric formats 🟢 95.7% |
![]() | ![]() |
| classic59 | Multi sheet summary 🟢 99.7% |
![]() | ![]() |
| classic60 | Large wide table 🟢 96.4% |
![]() | ![]() |
| classic61 | Product card with image 🟢 98.5% |
![]() | ![]() |
| classic62 | Company logo header 🟢 98.7% |
![]() | ![]() |
| classic63 | Two products side by side 🟢 98.3% |
![]() | ![]() |
| classic64 | Employee directory with photo 🟢 98.1% |
![]() | ![]() |
| classic65 | Inventory with product photos 🟢 97.3% |
![]() | ![]() |
| classic66 | Invoice with logo 🟢 98.4% |
![]() | ![]() |
| classic67 | Real estate listing 🟢 98.0% |
![]() | ![]() |
| classic68 | Restaurant menu 🟢 96.6% |
![]() | ![]() |
| classic69 | Image only sheet 🟢 97.3% |
![]() | ![]() |
| classic70 | Product catalog with images 🟢 96.8% |
![]() | ![]() |
| classic71 | Multi sheet with images 🟢 99.1% |
![]() | ![]() |
| classic72 | Bar chart image with data 🟢 97.4% |
![]() | ![]() |
| classic73 | Event flyer with banner 🟢 96.6% |
![]() | ![]() |
| classic74 | Dashboard with kpi image 🟢 95.6% |
![]() | ![]() |
| classic75 | Certificate with seal 🟢 98.7% |
![]() | ![]() |
| classic76 | Product image grid 🟢 97.9% |
![]() | ![]() |
| classic77 | News article with hero image 🟢 96.7% |
![]() | ![]() |
| classic78 | Small icon per row 🟢 98.7% |
| classic79 | Wide panoramic banner 🟢 96.4% |
![]() | ![]() |
| classic80 | Portrait tall image 🟢 98.6% |
![]() | ![]() |
| classic81 | Step by step with images 🟢 97.7% |
![]() | ![]() |
| classic82 | Before after images 🟢 96.2% |
![]() | ![]() |
| classic83 | Color swatch palette 🟢 97.9% |
![]() | ![]() |
| classic84 | Travel destination cards 🟢 96.5% |
![]() | ![]() |
| classic85 | Lab results with image 🟢 91.5% |
![]() | ![]() |
| classic86 | Software screenshot features 🟢 97.8% |
![]() | ![]() |
| classic87 | Sports results with logos 🟢 99.3% |
![]() | ![]() |
| classic88 | Image after data 🟢 98.7% |
![]() | ![]() |
| classic89 | Nutrition label with image 🟢 98.3% |
![]() | ![]() |
| classic90 | Project status with milestones 🟢 94.1% |
![]() | ![]() |
This project is licensed under the Apache License 2.0.