Hardware FixRecommendedDevice not working? Your driver may be the problemCheck updates for common hardware issues.Fix DriversOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PC×
Skip to content
Redmond desk5 min

How to Fix “wkhtmltoimage Not Found” in XAMPP on Windows

When XAMPP cannot find wkhtmltoimage on Windows, verify the executable, test its absolute path, then configure PATH or your PHP wrapper and check the failing process.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

If Windows says wkhtmltoimage is not recognized, first confirm that wkhtmltoimage.exe exists in the bin directory of your wkhtmltopdf installation. Test it by its quoted full path. If it runs that way, fix command lookup by adding the containing directory to Windows PATH, or configure your PHP application or wrapper to use the full executable path. Then test from the same PHP caller and Windows account that reports the error.

What “wkhtmltoimage not found” means

wkhtmltoimage is a command-line tool in the wkhtmltopdf project. Its tools render HTML to images or PDFs using Qt WebKit and run headlessly (wkhtmltopdf project). On Windows, an error such as “’wkhtmltoimage’ is not recognized as an internal or external command” usually means the command interpreter cannot find the executable by name. It may also mean the executable is absent or the application is configured with the wrong path.

As an Amazon Associate I earn from qualifying purchases.

The correct installation directory depends on where you installed the software. A path such as C:Program Files (x86)wkhtmltopdfbin appears in an older project issue as one user’s location; it is not a universal default (wkhtmltopdf issue #3241).

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Find and test the executable

  1. Open the directory selected for the wkhtmltopdf installation and look for wkhtmltoimage.exe in its bin folder.
  2. If the file is missing, check that you downloaded and installed the appropriate package. The project download page lists Windows installers and 7z archives for 32-bit and 64-bit systems (official downloads).
  3. Open Command Prompt and run the executable by its full path, putting the path in quotes if it contains spaces:
    "C:pathtowkhtmltopdfbinwkhtmltoimage.exe" --version
    Replace the example path with the actual location on your computer. If the command prints a version, the executable launches; investigate command lookup or application configuration next. If Windows says the file cannot be found, check the path and installation.

Choose how the application will find wkhtmltoimage

Option Best fit Trade-off
Add the containing directory to Windows PATH Several command-line callers should be able to invoke wkhtmltoimage by name. Changes command lookup for processes that inherit the updated environment. Extend the existing value; do not replace it.
Set the application’s executable path A PHP wrapper or one application needs a specific binary. Configuration is scoped to that application, but an absolute path must be updated if the binary moves.

A PHP wrapper’s documentation describes both approaches: install and verify the binaries, then either set the executable path or make the binary available through PATH (KnpLabs Snappy documentation). The exact setting name depends on the wrapper or application.

#1 Best Overall

Add the bin directory to PATH

  1. In Windows, open the Environment Variables settings and edit the existing Path value for the account or system context that runs the relevant process.
  2. Add the directory that contains wkhtmltoimage.exe, for example C:pathtowkhtmltopdfbin. Add the directory, not the executable filename.
  3. Save the change, then open a new Command Prompt and run wkhtmltoimage --version. Existing terminals and processes may still have the old environment.
  4. Test through the PHP application as well. PHP’s Windows documentation notes that exec() starts cmd.exe to launch a command (PHP exec documentation).

Windows PATH and PATHEXT are important existing environment variables; PHP’s Windows installation guidance says to extend these rather than overwrite them (PHP installation on Windows). If you edit Path through the Environment Variables dialog, preserve its other entries.

Configure an explicit executable path

If your wrapper supports an executable setting, use the full path to wkhtmltoimage.exe, including the filename. For example, a PHP configuration value might need a string equivalent to C:pathtowkhtmltopdfbinwkhtmltoimage.exe. Follow the wrapper’s syntax and escaping rules; do not assume every wrapper uses the same option name. This method avoids relying on command-name lookup, but the stored path will need changing if you move or reinstall the binary.

Test from the failing XAMPP/PHP process

A successful test in your own terminal does not prove that Apache or a PHP script can resolve the same command. Check the caller that produces the error, its executable-path setting, and the Windows account and environment under which it runs. If you changed a user or system environment variable, restart the relevant process so it can inherit the updated environment. Test the actual application action again and check its error output.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #2
Dell Latitude 5420 14" FHD Business Laptop Computer, Intel Quad-Core i5-1145G7, 16GB DDR4 RAM, 256GB SSD, Camera, HDMI, Windows 11 Pro (Renewed)
  • 256 GB SSD of storage.
  • Multitasking is easy with 16GB of RAM
  • Equipped with a blazing fast Core i5 2.00 GHz processor.

If XAMPP was moved

Apache Friends says XAMPP’s setup script adjusts XAMPP configuration after a move, but it does not rewrite paths in user scripts (Apache Friends Windows FAQ). If XAMPP or wkhtmltopdf was relocated, inspect application configuration and scripts for an old absolute path to wkhtmltoimage.exe.

Troubleshooting by symptom

  • The full-path command fails with “file not found.” Check the spelling and actual install location, and verify wkhtmltoimage.exe is present. Revisit the Windows package and architecture options on the official download page.
  • The full-path command works, but the name-only command fails. The executable is present; add its containing bin directory to the relevant PATH, open a new terminal, and retry.
  • The terminal works, but the PHP application fails. Configure the path in the wrapper if supported, then test through the failing PHP caller. Check the process account and environment rather than assuming it sees your interactive terminal’s settings.
  • The error returns after moving XAMPP or wkhtmltopdf. Update any application or script setting that still points to the old location; XAMPP’s move setup does not update user scripts.
  • The command is found but rendering still fails. That is a different failure from “not found.” Confirm the binary runs directly, inspect the application’s command and error output, and check whether the HTML or invocation is valid for the tool. Do not treat every rendering failure as a PATH problem.

Security and version considerations

The wkhtmltopdf downloads page identifies 0.12.6, released June 11, 2020, as its current stable series; that is the page’s stated release information, not proof that no later software exists (official downloads). The same page warns: “Do not use wkhtmltopdf with any untrusted HTML – be sure to sanitize any user-supplied HTML/JS, otherwise it can lead to complete takeover of the server it is running on!” Treat HTML and JavaScript supplied by users as untrusted, and assess whether this tool is suitable for your security and maintenance requirements.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Or skip the browser setup

If your goal is to capture a website rather than specifically repair this local executable, ScreenshotNeo is a screenshot API and MCP server for developers. It can return a PNG, JPEG, WebP, or PDF from one GET request. For example, save a WebP screenshot of Stripe with cURL:

Rank #3
15.6 Inch Win 11 Laptop Computer, N4020, 4GB DDR4 RAM, 128GB Storage
  • WINDOWS 11 | STABLE PERFORMANCE: Powered by Intel Celeron N4020 processor and Windows 11 system, this laptop delivers stable performance for everyday computing tasks. It supports web browsing, online learning, document editing, email communication, and basic office work with optimized power efficiency, providing a practical and reliable experience for essential daily use for daily use.
  • 15.6” FHD IPS DISPLAY: Features a 15.6-inch Full HD IPS display with narrow bezels, offering wider viewing angles and clearer image details compared to standard panels. The improved screen-to-body ratio enhances visual experience for study, reading, document work, and video playback, making it suitable for both productivity and entertainment use.
  • 4GB DDR4 + 128GB eMMC STORAGE: Equipped with 4GB DDR4 memory and 128GB eMMC storage for everyday basics such as browsing, documents, email, and online learning platforms. The built-in TF card slot supports storage expansion up to 1TB, giving you more flexibility for files, photos, videos, and daily documents. TF card not included.
  • CONNECTIVITY & PORTS: Includes 1× TF card slot, 2× USB 3.2 Gen1 ports, and 2× full-featured Type-C ports (USB 3.2 Gen1). The Type-C ports support data transfer, charging, and video output, enabling flexible connection with external devices such as monitors, storage, and peripherals for daily work and study use.
  • LIGHTWEIGHT DESIGN | ONLINE COMMUNICATION: Designed with a slim, portable profile, this laptop is easy to carry for school, commuting, and travel. A built-in 1MP front camera supports online classes, video meetings, remote communication, and everyday conferencing. The 3300mAh battery works with the low-power system design to support practical daily use, while thermal optimization helps maintain quieter operation during extended tasks.

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

See the ScreenshotNeo API documentation for request options. ScreenshotNeo removes cookie and consent banners, newsletter popups, and chat widgets before capture; each step can be turned off. Bot checks, blank pages, failed loads, timeouts, and cache hits are not billed, and responses identify the page verdict and billing status in headers. Its MCP server lets AI agents use take_screenshot, get_page_info, and capture_pdf. The free plan includes 1,000 screenshots a month with no card; paid plans start at $5 for 3,000 shots.

Sign up for 1,000 free screenshots a month, with no card.

Quick Recap

Bestseller No. 1
HP 14' HD Laptop, Windows 11, Intel Celeron Dual-Core Processor Up to 2.60GHz, 4GB RAM, 64GB SSD, Webcam, Dale Pink (Renewed)
HP 14" HD Laptop, Windows 11, Intel Celeron Dual-Core Processor Up to 2.60GHz, 4GB RAM, 64GB SSD, Webcam, Dale Pink (Renewed)
14" diagonal, 1366x768 resolution, HD BrightView LED, Glossy NON-TOUCH Display
$245.99
Bestseller No. 2
Dell Latitude 5420 14' FHD Business Laptop Computer, Intel Quad-Core i5-1145G7, 16GB DDR4 RAM, 256GB SSD, Camera, HDMI, Windows 11 Pro (Renewed)
Dell Latitude 5420 14" FHD Business Laptop Computer, Intel Quad-Core i5-1145G7, 16GB DDR4 RAM, 256GB SSD, Camera, HDMI, Windows 11 Pro (Renewed)
256 GB SSD of storage.; Multitasking is easy with 16GB of RAM; Equipped with a blazing fast Core i5 2.00 GHz processor.
$285.00

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.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Windows Errors? Fix Them Before They SpreadFree repair scan
Outdated Drivers Are Slowing You DownFree scan - exact matches

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.