We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to publish HTML to PDF converter to server

Converting HTML to PDF in Web application from scratch using WebKit HTML converter. This documentation contains three sections:

  • HTML to PDF conversion in local machine.
  • Publishing the project to server.
  • Troubleshooting the conversion failure in server.

Assemblies Required

  • Syncfusion.Compression.Base.dll
  • Syncfusion.HtmlConverter.Base.dll
  • Syncfusion.Pdf.Base.dll
  • QtBinaries folder

You can get all these assemblies by installing the WebKit installer in the following link.

WebKit HTML Converter: https://www.syncfusion.com/downloadslatest-version

HTML to PDF conversion in local machine

  1. Create a new ASP.NET MVC project.


  1. Copy the required assemblies and QtBinaries from the WebKit installed location to project folder.


  1. Refer the copied assemblies in the project by using reference manager.


  1. Include the QtBinaries folder in the project and set Copy to Output Directory as Copy always for all files in the QtBinaries folder.



  1. Add button to export the web page to PDF in index.cshtml and add the following code snippet in controller.




  1. Run the project and test the HTML conversion in local computer.

Publishing the project to server

  1. Publish the project to a local file folder.



  1. It will publish the required files to the local publish folder.


  1. Copy the published output folder to the server and host the application in IIS.
  1. Open the IIS manager in the server and add new website.
  2. Provide site name and select the physical path of the published output folder on the server.

  1. Get the IP address of the server after adding the website in local IIS server.
  2. Browse the website using the IP address and port number from the local computer. Once the website is loaded, export the webpage to PDF.



Troubleshooting the conversion failure in server

Refer to the following links for troubleshooting the conversion failure in the server.

UG: https://help.syncfusion.com/file-formats/pdf/converting-html-to-pdf#troubleshooting 

KB: https://www.syncfusion.com/kb/8208/failed-to-convert-the-webpage-exception-with-webkit-html-converter



Article ID: Published Date: Last Revised Date: Platform: Control:
8841 06/14/2018 06/26/2018 ASP.NET MVC PDF
Did you find this information helpful?
Add Comment
You must log in to leave a comment

Please sign in to access our KB

or the page will be automatically redirected to sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon