Forum Discussion
Uomasm
Aug 21, 2026Tin Contributor
How to convert png image to pdf format on Windows 11?
I need to convert multiple PNG images to a single PDF file on Windows 11 and am looking for the best built-in method. Can someone guide me on how to do this without installing third-party software, o...
AidenWhite
Aug 21, 2026Iron Contributor
For developers and power users who want a highly customizable solution, combining Python with the Pillow and PyPDF2 libraries is an excellent choice. This scripting approach provides ultimate flexibility and is perfect for anyone looking to automate their workflow when figuring out how to convert png to pdf in bulk.
Steps:
- Install Python and the required libraries via command line:
pip install Pillow PyPDF2
- Write a Python script that contains the following code:
import os
from PIL import Image
from PyPDF2 import PdfMerger
# Convert PNGs to PDFs and merge them
merger = PdfMerger()
png_files = sorted([f for f in os.listdir('.') if f.endswith('.png')])
for png in png_files:
img = Image.open(png)
pdf = png.replace('.png', '.pdf')
img.save(pdf, 'PDF', resolution=100)
merger.append(pdf)
merger.write('output.pdf')
merger.close()
# Clean up individual PDFs
for png in png_files:
pdf = png.replace('.png', '.pdf')
os.remove(pdf)- Run the script in the folder containing the PNG files:
python convert_png_to_pdf.py
This method is the ultimate answer to how to convert png to pdf for those who frequently process large batches of images and prefer a scriptable, hands-off automation over manual GUI tools.