Batch convert all your Publisher files to PDF (free script)
If you still have Microsoft Publisher on a Windows PC, you can convert every .pub file you own to PDF in one go, before October 1, 2026, when Publisher stops working in Microsoft 365. This free script does exactly that. We tested it with Publisher for Microsoft 365.
What it does
- Finds every
.pub file in the folder you choose, including all subfolders
- Opens each one in your copy of Publisher and saves a high-quality PDF next to it
- Skips files that already have a PDF, so you can safely run it again
- Lists any files it couldn't open at the end
How to use it
- Download Convert-PubToPdf.ps1 (a plain text file you can open in Notepad to read first).
- Right-click the downloaded file and choose Run with PowerShell.
- Pick the folder that holds your Publisher files, such as Documents.
- Leave it running. Each file takes a few seconds. Your PDFs appear next to the originals.
If Windows blocks the script, open PowerShell and run:
powershell -ExecutionPolicy Bypass -File "$HOME\Downloads\Convert-PubToPdf.ps1"
Good to know
- Keep your .pub files too. The PDFs are your readable archive, but keep the originals in case you ever want to reopen them.
- Editing later: PDFs can be opened in Word or imported into Canva to edit. Complex layouts may shift a little.
- Files on OneDrive or SharePoint: make sure they're synced to your PC ("Always keep on this device") before running.
No Publisher, on a Mac, or hundreds of files? Drop them on PubRescue. We convert every file with genuine Microsoft Publisher to a print-perfect PDF plus an editable copy that keeps your layout (for PowerPoint, Google Slides and Canva), and you see a free preview before paying.
Convert my .pub files →