PDF to HTML Conversion is a widely and commonly used function that can be achieved through different means e.g. software, tools, and online services. Sometimes you need to convert your PDF content in a way that it can be displayed in the browser or become a part of your web application. PDF to HTML Conversion lets you achieve this requirement where PDF content renders with HTML tags with similar styling and formatting. Thanks to Aspose, you can implement the functionality now in your desktop or web application using Aspose.PDF for .NET. API allows you to convert your PDF documents into HTML using a few lines of code and not only this, but it also lets you specify different formatting and styling options during conversion. The following section of the post will take you to the complete tour guide on how to use Aspose.PDF for .NET in order to convert PDF to HTML.

PDF to HTML Conversion in .NET

A simple PDF to HTML Conversion can take place by loading a PDF document and save it as HTML using HtmlSaveOptions. Following example shows not only conversion but specification of a requirement where you can save images as raster format:

The story doesn’t end here. Aspose.PDF for .NET offers massive and most demanding features which not only increases its usability but give you full control over the conversion process as per your desire. You can go through following outstanding and comprehensive articles in API documentation in order to understand the full feature set in this domain i.e. PDF to HTML:

In addition to the above features, Aspose.PDF for .NET 19.8 brings a new enhancement where you can save PDF to HTML with full content width. Let’s have a look on this new feature usage:

PDF to HTML Conversion with Full Content Width

Latest version of the API allows you converting PDF to HTML with full content width whereas HTML content is used to be left-aligned. The FlowLayoutParagraphFullWidth property of HtmlSaveOptions class lets you achieve this as shown in the following code sample.

Further Improvements and Useful Fixes

The usability factor of the API becomes stronger with the following list of useful improvements that API brings with it in v19.8:

  • Adding Table functionality is further rectified
  • Font substitution is further improved
  • Memory consumption during adding HTML in PDF is further improvised
  • PDF to Image conversion is improved
  • XML to PDF conversion is further improved
  • PDF to DOC/DOCX conversion is improved
  • Text adding and processing scenarios have further been improvised

We hope that we covered every aspect of PDF to HTML Conversion in above guide. However, in case you still have any inquiry, please feel free to let us know. Like always, do not miss a single update about Aspose APIs. We will be back soon with a new revision of API with exciting features.