OSError: No wkhtmltopdf executable found: "b''"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-21-2023 05:23 AM
OSError: No wkhtmltopdf executable found: "b''"
If this file exists please check that this process can read it or you can pass path to it manually in method call, check README. Otherwise please install wkhtmltopdf - https://github.com/JazzCore/python-pdfkit/wiki/Installing-wkhtmltopdf
Can anyone help me how can i solve this error

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-22-2023 09:26 PM
@feed expedition :
The error message indicates that the wkhtmltopdf executable file cannot be found. This file is required by the pdfkit library to generate PDF files.
You can try the following steps to resolve the issue:
- Install wkhtmltopdf on your system:
- For Linux systems, you can try running the following command in your terminal:
- sudo apt-get install wkhtmltopdf
- For Windows, you can download the installer from the official website: https://wkhtmltopdf.org/downloads.html
- If you have already installed wkhtmltopdf make sure that it is added to the PATH environment variable. You can check this by running echo $PATH on Linux or echo %PATH% on Windows.
- If wkhtmltopdf is installed but still cannot be found, you can try passing the path to the pdfkit function manually. For example:
import pdfkit
# Set the path to wkhtmltopdf executable file
path_wkhtmltopdf = '/usr/local/bin/wkhtmltopdf' # This may vary depending on your system
config = pdfkit.configuration(wkhtmltopdf=path_wkhtmltopdf)
# Use the configuration when generating PDF
pdfkit.from_url('http://google.com', 'out.pdf', configuration=config)
I hope this helps you to resolve the issue.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-29-2023 07:19 AM
Thank you sooooooo much!! I met this problem, too, and it works!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-26-2023 10:06 PM
Hi @feed expedition
Thank you for posting your question in our community!
Share the wisdom! By marking the best answers, you help others in our community find valuable information quickly and efficiently.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-02-2023 11:17 PM
Hi, When did you receive this error? running a code insde a notebook , or running a cluster? or a job?
Also, please tag @Debayan with your next response which will notify me. Thank you!

