Mark Stephens Mark has been working with Java and PDF since 1999 and is a big NetBeans fan. He enjoys speaking at conferences. He has an MA in Medieval History and a passion for reading.

How to convert PDF to HTML in Java (Tutorial)

1 min read

PDF forms to HTML forms using Java (Icon)

PDF to HTML using Java (Icon)
In this article I will show you how you can convert PDF files to HTML in Java using our library BuildVu. PDF to HTML conversion helps you to optimise your PDF content for display on browsers. We have a separate article explaining the benefits of converting PDF to HTML.

How to convert PDF to HTML using Java

  1. Download the BuildVu trial jar
  2. Add the BuildVu Jar to your project libraries
  3. Choose conversion options
  4. Choose viewer options
  5. Set PDF file path and output directory

How to convert PDF to HTML from the command line

You can run BuildVu to convert directly from the command line which is useful for running the converter from another language or script.

  1. Download the BuildVu trial jar
  2. Set the input directory and output directory
  3. Choose conversion options
  4. Increase the XMX value according to need


The default mode generates the document inside the IDRViewer. To generate just the raw content to be used inside your own custom solution, you can use:

You can check out documentation for BuildVu to learn more on how to turn PDF into an HTML using Java. If you want to convert PDF to SVG you can check out our other article here.



BuildVu allows you to

View PDF files in a Web app
Convert PDF documents to HTML5
Parse PDF documents as HTML
Mark Stephens Mark has been working with Java and PDF since 1999 and is a big NetBeans fan. He enjoys speaking at conferences. He has an MA in Medieval History and a passion for reading.