Understanding the Error Context
The Microsoft Print to PDF printer is a built-in virtual printer included with Windows 10 and Windows Server 2019. It allows users to print documents to PDF files without installing third-party software. However, on server operating systems, this feature is often disabled by default to reduce the attack surface and remove unnecessary roles. When an administrator attempts to add it via the standard Control Panel interface, the system may fail to locate the required driver files, resulting in the generic "Element Not Found" error. This usually indicates that the feature was either never installed or has been removed during a previous cleanup operation.
Verifying Feature Status
Before attempting repairs, you should verify whether the feature is currently enabled or disabled on your server. The most reliable way to check this is by using PowerShell, as it provides immediate feedback on the installation state of optional features. Open PowerShell as an Administrator and run the following command:
Get-WindowsOptionalFeature -Online -FeatureName PrintService-PrintToPDF
If the State column shows Disabled, the feature is present but turned off. If it shows Unavailable, the feature files are missing from the component store, which requires a different repair approach. In most cases of the "Element Not Found" error, the state is simply Disabled, meaning you only need to enable it rather than reinstall the entire driver package.
Enabling the Printer via PowerShell
Once you have confirmed the feature is disabled, you can enable it directly through PowerShell. This method bypasses the graphical interface that often fails due to permission issues or cached errors. Run the following command in your elevated PowerShell session:
Enable-WindowsOptionalFeature -Online -FeatureName PrintService-PrintToPDF -NoRestart
The -NoRestart flag prevents an immediate reboot, allowing you to continue working. After the command completes successfully, you must restart the Print Spooler service to recognize the new printer. Execute these commands to restart the service:
Stop-Service -Name Spooler
Start-Service -Name Spooler
After restarting the spooler, open the Devices and Printers section in Control Panel. The Microsoft Print to PDF printer should now appear in the list. If it does not appear immediately, log off and log back into your user account to refresh the printer enumeration cache.
Repairing Missing Component Store Files
If the PowerShell command returns an error stating that the source files are missing, you must repair the Windows component store. This happens if the feature was previously removed using DISM or if system files were deleted. To fix this, you need to point DISM to a valid source of Windows installation files. Mount your Windows Server 2019 ISO image or copy the sources\sxs folder to a local directory like C:\WSUSource.
Then, run the following DISM command to restore the feature from the local source:
DISM /Online /Enable-Feature /FeatureName:PrintService-PrintToPDF /Source:C:\WSUSource\sxs /LimitAccess
This process extracts the necessary drivers and registers them with the operating system. Once completed, restart the print spooler as described in the previous section. This method is particularly useful if you have performed a minimal installation of Windows Server 2019 where many optional features were excluded.
Alternative Manual Installation Steps
In some rare cases, automatic detection fails due to registry corruption. You can manually add the printer by going to Control Panel > Devices and Printers > Add a printer. Select The printer that I want isn't listed. Choose Add a local printer or network printer with manual settings and select Use an existing port. For the port name, enter PDF:. Click Next, and then select Microsoft on the left and Microsoft Print to PDF on the right. This forces Windows to load the specific driver associated with the virtual port.
For more information on managing PDF workflows, you might also find our guide on how to change file type associations helpful for ensuring the correct application opens generated PDFs.
Frequently Asked Questions
Why does the printer disappear after a reboot?
This usually happens if the Print Spooler service is configured to start manually instead of automatically. Ensure that the service startup type is set to Automatic so it initializes properly during boot. Additionally, check Group Policy settings that might disable optional features upon login.
Can I use this printer on Windows Server 2016?
No, the Microsoft Print to PDF feature is not available in Windows Server 2016. It was introduced in Windows 10 and Windows Server 2019. Servers running older versions must use third-party PDF printers or upgrade to a supported OS version to access this native functionality.
How do I remove the Print to PDF printer completely?
To remove the printer, you must first disable the underlying feature. Use the PowerShell command Disable-WindowsOptionalFeature -Online -FeatureName PrintService-PrintToPDF. After disabling, delete the printer icon from Devices and Printers. A reboot will ensure all associated services are stopped.
Is it safe to delete the Print Spooler service?
Never delete the Print Spooler service itself, as it is critical for all printing operations on Windows. Deleting it will break all physical and virtual printers. Instead, if you encounter errors, restart the service or clear the C:\Windows\System32\spool\PRINTERS folder to remove stuck jobs.
What if the "Element Not Found" error persists after enabling the feature?
If the error continues, check the Event Viewer under Applications and Services Logs > Microsoft > Windows > Printing. Look for error codes related to driver loading. Corrupted system files may require running sfc /scannow to repair core Windows components before the printer feature can function correctly.