What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
If AWS Lambda reports wkhtmltopdf: command not found, the deployed function cannot find the executable. Installing wkhtmltopdf on your computer does not put it in Lambda. Package a Linux-compatible executable with the function, add it in a Lambda layer, or include it in a container image—and call it by its correct path or make its directory available on PATH.
What the error means—and what to check first
This message is a command-resolution failure: the process running in Lambda cannot resolve the name wkhtmltopdf to an executable. Start with the artifact Lambda actually runs, not the machine where you wrote or built the function.
- Inspect the deployment. Confirm the ZIP, attached layer, or container image contains the executable. A file present only on your workstation or in a temporary build stage is not available to the deployed function.
- Check the path. If the file is in a layer at
bin/wkhtmltopdf, Lambda extracts that layer under/opt, so try/opt/bin/wkhtmltopdf. AWS documents layerbinas a PATH directory for all runtimes; an explicit path makes it clear which file your code is invoking. - Check native compatibility. A Linux executable must match the function’s configured architecture, x86-64 or arm64, and be compatible with its runtime environment. A macOS or Windows executable will not become usable just because it is inside a ZIP.
- Recheck the error after deployment. If the message changes to a missing shared-library error, command lookup is no longer the only issue. The executable may need libraries or other runtime files that are not in the package.
AWS’s layer packaging guidance says: “Because Lambda functions run on Amazon Linux, your layer content must be able to compile and build in a Linux environment.” AWS recommends building layer content in Linux and identifies Docker as one way to do that.
Choose a packaging method
Both ZIP deployments with a layer and Lambda container images can package a native executable. The right choice depends on your current deployment workflow and how much control you need over the operating system and native dependencies. Neither is universally better.
Do these 3 things before closing this tab:
1Repair Windows errors before they cause bigger problems2Fix the driver behind crashes, sound loss and screen glitches3Clear out junk files and repair common Windows errors#1 Best Overall
- INNOVATIVE CARTRIDGE-FREE PRINTING — No more dealing with lots of tiny ink cartridges; With this wireless document and photo printer each ink bottle set is equivalent to about 90 individual cartridges²
- LESS FREQUENT INK REPLACEMENT — Replacement ink bottles don't have to be changed nearly as often as ink cartridges¹; When you choose this combination printer, scanner and copier you can print up to 4,500 pages black/7,500 color³
- COLOR PRINTING — Up to 2 years of ink in the box4 (and with every replacement ink set) for fewer out-of-ink frustrations
- ZERO CARTRIDGE WASTE — By using an Epson EcoTank printer you can help reduce the amount of cartridge waste ending up in landfills
- HOME PRINTER DESIGNED FOR RELIABILITY — The Epson EcoTank ET-2800 All-in-One Supertank Color Printer creates vivid, detailed prints and documents thanks to Micro Piezo Heat-Free Technology; Fire off 10 ISO pages per minute1 to easily finish large jobs
| Option | What goes in the deployment | Best fit | What to verify |
|---|---|---|---|
| Function ZIP | Your handler and the executable, plus any required supporting files, in the function package. | A small deployment where keeping the executable with the handler suits your existing process. | The deployed ZIP contains the files at the paths your code uses, and the executable matches the Lambda runtime and architecture. |
| ZIP plus Lambda layer | The function ZIP contains application code; a layer ZIP contains supplementary executable and dependency files. | When you want to package native files separately from application code. | The layer archive has the expected top-level directories, and its contents are available below /opt. |
| Container image | The image includes the application and the executable dependencies. | When your deployment workflow already builds and publishes Lambda container images, or you need to manage the OS and native files together. | The image’s base environment, executable, libraries, and architecture all match the function configuration. For AL2023-based Lambda images, AWS identifies microdnf (also linked as dnf) in place of AL2’s yum. |
Package wkhtmltopdf in a ZIP-based Lambda deployment
Build a layer with the expected paths
For a layer, place the executable under a top-level bin directory in the layer archive. Any layer libraries belong under a top-level lib directory. AWS documents lib as an LD_LIBRARY_PATH directory for all runtimes. The following commands package files you have already obtained or built for a compatible Linux environment; they do not install wkhtmltopdf or prove that a particular binary is compatible.
mkdir -p layer/bin layer/lib
cp /path/to/linux/wkhtmltopdf layer/bin/wkhtmltopdf
chmod 755 layer/bin/wkhtmltopdf
# If needed, copy compatible shared libraries into layer/lib/.
cd layer
zip -r ../wkhtmltopdf-layer.zip .
cd ..
Inspect the archive before attaching it. Its entries should start with bin/ and, if you bundled libraries, lib/—not an extra enclosing directory such as layer/bin/. Then attach the layer to the function using your usual Lambda deployment workflow.
unzip -l wkhtmltopdf-layer.zip
With the expected layer layout, invoke the binary directly as /opt/bin/wkhtmltopdf. This avoids depending on PATH lookup. If you put the executable in the function ZIP instead, use its actual deployed path and make sure that location is executable.
Rank #2
- CARTRIDGE-FREE PRINTING — Print lab-quality photos, graphics and creative projects; Get vibrant colors and sharp text with Epson's high-accuracy printhead and Claria ET Premium 6-color inks
- INK BOTTLES — Save on photos1 and creative projects with affordable in-house printing; All-in-one printer allows you to print 4" x 6" photos for about 4 cents each vs. 40 cents with traditional ink cartridges1
- LESS FREQUENT INK REPLACEMENT — Replacement ink bottles don't have to be changed nearly as often as ink cartridges¹; Printer, scanner and copier lets you print up to 6,200 color pages³
- PRINT FOR LONGER — Up to 2 years of ink in the box² (and with every replacement ink set) for fewer out-of-ink frustrations with this wireless printer
- ZERO CARTRIDGE WASTE — Epson EcoTank printer helps reduce the amount of cartridge waste ending up in landfills; Cartridge-free printer uses high-yield ink bottles; Each replacement ink bottle set is equivalent to about 100 individual ink cartridges⁴
Call it from Python using an explicit path
This handler illustrates invoking a local input file and writing a PDF to the Lambda temporary directory. Adapt the paths and error handling to your application. It assumes the executable and any required libraries have already been packaged correctly.
Crashes, No Sound, or Screen Glitches?
Random freezes, missing sound and display glitches usually trace back to one bad driver. Find and replace yours safely.Free scan · under a minuteWindows Errors? Fix Them Before They Spread
Repair common Windows errors and clear accumulated junk for a smoother, more stable PC - no reinstall needed.Free scan · no reinstallimport os
import subprocess
WKHTMLTOPDF = "/opt/bin/wkhtmltopdf"
def handler(event, context):
html_path = "/tmp/input.html"
pdf_path = "/tmp/output.pdf"
if not os.path.isfile(WKHTMLTOPDF):
raise FileNotFoundError(
f"wkhtmltopdf is missing at {WKHTMLTOPDF}; check the deployed ZIP or layer"
)
if not os.access(WKHTMLTOPDF, os.X_OK):
raise PermissionError(f"wkhtmltopdf is not executable: {WKHTMLTOPDF}")
if not os.path.isfile(html_path):
raise FileNotFoundError(f"HTML input is missing: {html_path}")
result = subprocess.run(
[WKHTMLTOPDF, html_path, pdf_path],
check=True,
capture_output=True,
text=True,
timeout=60,
)
return {
"pdf_path": pdf_path,
"stdout": result.stdout,
"stderr": result.stderr,
}
The example uses an explicit argument list rather than a shell command string, so spaces in paths are handled as arguments and the process does not depend on a shell to resolve the executable. The input file must exist in the running function; packaging the binary does not create your HTML input. Choose a timeout suitable for your workload and the function’s configured limits.
Resolve shared-library and architecture problems
If Lambda now finds the executable but reports a loader or shared-library error, inspect the native dependencies rather than changing PATH repeatedly. The executable may depend on libraries, fonts, or font configuration that were not included. Bundle only files that are compatible with the Lambda environment and your selected architecture; for a layer, place libraries in its lib directory. If the binary expects libraries in another location, configure the runtime accordingly and verify the final environment.
Rank #3
- SET IT UP ONCE AND PRINT WITH CONFIDENCE. No complicated maintenance. Just easy, reliable printing you can count on.
- INK FOR YEARS. NOT MONTHS. Up to 2 years of ink included. Get thousands of pages of cartridge-free printing. More pages, less hassle
- KEEPS PRINTING WELL AFTER COMPETITORS HAVE QUIT. No complex maintenance. Sharper text, richer colors.[2] Only with HP Smart Tank
- PREMIUM SUPPORT - Strong technical expertise to solve issues faster
- THE LAST PRINTER YOU'LL EVER NEED. Enjoy years of refillable, cartridge-free printing.
A third-party AL2023 example, malwazan/wkhtmltopdf-amazon-linux-2023, describes a layer containing a wrapper, executable, libraries, fonts, and font configuration, with callers using /opt/bin/wkhtmltopdf. Treat it as an example to audit, not an AWS-supported recipe: its listing does not establish security, maintenance, or compatibility with your particular runtime and architecture. Inspect the build inputs and validate it in your own function before relying on it.
Use a Lambda container image instead
A container image can package the application, wkhtmltopdf, and its native dependencies together. Build from a Lambda-compatible image for the runtime and architecture configured for the function, and ensure the final image—not merely an intermediate build stage—contains the executable at the path your handler invokes.
The Tool Desk
Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →Check the image generation before using package-manager instructions. AWS distinguishes AL2023-based Lambda images, which use microdnf (also available as dnf), from Amazon Linux 2 images, which use yum. That distinction does not mean wkhtmltopdf is available from every image’s repositories. Confirm package availability and compatibility rather than copying an AL2 installation command into an AL2023 build. If you build or copy the executable separately, include and validate its supporting libraries in the final image.
Rank #4
- Wireless Bluetooth Printer: Portable thermal printer compatible with iPhone, Android phones, iPad and tablet computers via Bluetooth. For smartphones, please download the "Nada Print" App. You can also connect to laptops and computers for printing using a USB-C cable. (Note: Laptops and computers can only be connected via USB and require the installation of a driver first. Bluetooth connection is not supported.)
- No-ink printing: Only supports US Letter and A4 size thermal paper.(Doesn't support regular paper) The no-ink portable thermal printer uses direct thermal technology, requiring no ink, toner or ribbons, making it environmentally friendly, cost-effective and time-saving. The thermal printer package comes with a roll of US Letter thermal printing paper. Note: When installing the paper, remember to switch the paper size switch on APP
- Clear Print: NDYIN N80 portable thermal printer adopts high-definition printing technology, with a 203DPI resolution to provide you with clear printing results. This mobile printer is compatible with roll paper, folded paper and tattoo transfer paper, supporting printing from your mobile phone PDF, Word, pictures and web pages anytime and anywhere. It is recommended to use our NDYIN thermal paper to achieve good printing quality
- Portable wireless printer for travel: The thermal printer is equipped with a built-in 1500mAh rechargeable battery, which can print 160 sheets of 8.5" x 11" thermal paper after being fully charged. It weighs only 1.5 pounds and is compact in size. This ink-free portable printer can be easily carried in a backpack or briefcase! It is perfect for business travel, cars, small offices, construction sites, schools and homes. You can print documents, contracts, invoices and boarding passes anytime and anywhere
- The N80 thermal printer has a wide range of uses. The package includes the N80 printer, a roll of US Letter paper(7m/roll), a user manual, a guide card, a type-C soft cable and a type C adapter. Note: The charging adapter is not included. Special thermal paper is required for use; ordinary paper cannot be used. This ink-free portable thermal printer is suitable for various scenarios such as home, school, travel, office, and outdoor, meeting the printing needs of different groups of people. This tattoo template printer is also compatible with tattoo transfer paper, making it an ideal choice for tattoo art
Troubleshoot by the exact failure
wkhtmltopdf: command not found
- Cause: The executable is absent from the deployed artifact, stored at a different path, or not discoverable through PATH.
- Fix: Inspect the actual ZIP, attached layer, or final image. For the documented layer layout, test the explicit path
/opt/bin/wkhtmltopdfand verify that the archive hasbin/at its top level.
No such file or directory even though the file appears present
- Cause: The path used by the process does not match the deployed path. Native binary or loader incompatibility can also surface as a file-not-found-style launch failure.
- Fix: Confirm the exact path and architecture, and check whether the executable was built for a compatible Linux environment. Do not assume that a file listing alone proves it can run.
Permission denied
- Cause: The file lacks execute permission or is being invoked from a location or packaging setup that does not permit execution.
- Fix: Set executable permissions when packaging (for example,
chmod 755), then inspect the deployed artifact and verify the path being invoked.
A shared-library or loader error replaces the command error
- Cause: Lambda can start the executable but cannot find one of its native dependencies.
- Fix: Identify the missing library, include a compatible copy with the deployment, and use the correct library search path. For a layer, AWS documents
libunder/optas a library search location; a wrapper may be needed for dependencies outside that path.
It works locally but not after deployment
- Cause: Your local operating system, installed libraries, architecture, or PATH differs from Lambda’s runtime environment.
- Fix: Build or validate the packaged native files in a Linux environment compatible with the Lambda runtime, check the configured x86-64 or arm64 architecture, and test the artifact that is actually deployed.
Or skip the browser setup
If your input is a publicly accessible webpage and you need a clean screenshot or PDF rather than a Lambda-hosted wkhtmltopdf conversion of local or generated HTML, ScreenshotNeo can take the URL directly. It is a different workflow, not a drop-in executable for rendering arbitrary local files.
One GET request returns a screenshot or PDF. This cURL example saves a WebP screenshot:
Quick Recap
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
See the ScreenshotNeo API documentation for request options. Cookie banners, popups, and chat widgets are removed before the shot; bot checks, blank pages, and failed loads are never billed; an MCP server lets AI agents take screenshots; and 1,000 screenshots a month are free with no card, with paid plans starting at $5 for 3,000. Sign up for 1,000 free screenshots a month with no card.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

