Offline PDF Conversion: Best Tips, Scripts & Automation for Office Users

You can convert Excel or Word files to PDF without using any external software or online service by using features that are already built into Microsoft Office and your operating system (Windows or macOS). Here’s how you can do it step by step:


✅ Method 1: Using “Save As” in Microsoft Office (Word or Excel)

🪟 For Windows:

  1. Open your Word or Excel file in Microsoft Office.
  2. Click on File in the top-left corner.
  3. Select Save As.
  4. Choose the location (e.g., “This PC”, Desktop, etc.).
  5. In the “Save as type” dropdown menu, select PDF (*.pdf).
  6. Click Save.

👉 Result: Your file will be converted and saved as a PDF in the chosen location.


🍎 For macOS:

  1. Open your Word or Excel file.
  2. Click File > Save As or File > Export.
  3. Select PDF from the file format options.
  4. Choose the location and click Save.

✅ Method 2: Using “Print to PDF” (Built-in printer feature)

This method works even if you don’t have Office installed, and are using free editors like WordPad or any viewer.

🪟 For Windows 10/11:

  1. Open the document (in Word, Excel, or any program that supports printing).
  2. Press Ctrl + P to open the print dialog.
  3. From the printer list, select Microsoft Print to PDF.
  4. Click Print.
  5. Choose a location and name for the PDF file.
  6. Click Save.

👉 Note: This doesn’t physically print—it creates a PDF instead.


🍎 For macOS:

  1. Open the document in any app.
  2. Press Cmd + P to open the print dialog.
  3. At the bottom-left corner of the print window, click the PDF button.
  4. Select Save as PDF.
  5. Choose the location and click Save.

✅ Advantages of These Built-in Methods:

  • ✔️ No internet required.
  • ✔️ No need to install third-party apps.
  • ✔️ Preserves layout and formatting accurately.
  • ✔️ Secure and private—your document stays on your device.

WINDOWS: Automate “Print to PDF” with a Shortcut

✅ Option 1: Using a Batch Script for Automatic PDF Conversion (for .docx or .xlsx files)

🧠 Requires Microsoft Word or Excel installed and “Microsoft Print to PDF” enabled.

📁 Step-by-Step:

  1. Open Notepad.
  2. Paste the following script for Word:
batCopyEdit@echo off
set input=%1
set output=%~dpn1.pdf
"C:\Program Files\Microsoft Office\root\Office16\WINWORD.EXE" /mFilePrintDefault /q /n "%input%"
timeout /t 2 > nul

Replace the Office path (Office16) if you have a different version (e.g., Office15, Office14).

  1. Save the file as ConvertToPDF.bat.
  2. Drag and drop your .docx or .xlsx file onto this .bat file.
  3. The document will auto open, print to PDF, and close.

✅ Option 2: Add “Print to PDF” as a Right-Click Option

  1. Press Win + R, type shell:sendto → press Enter.
  2. Inside the opened folder, right-click → New > Shortcut.
  3. Enter this location:
shellCopyEdit%windir%\System32\printui.exe

This allows you to customize printing preferences.

  1. Name the shortcut: Send to PDF Printer.

Now, when you right-click a file, go to Send To > Send to PDF Printer to trigger the print dialog preloaded with PDF output.


🍎 macOS: Automate “Save as PDF” Using Automator

✅ Create a Quick Action to Print to PDF

  1. Open Automator from Applications.
  2. Choose New Document > Quick Action.
  3. Set the top options:
    • Workflow receives current: PDF files
    • in: Finder
  4. In the left panel, search for “Print Finder Items”.
  5. Drag it to the workflow area.
  6. Choose Printer: Save as PDF.
  7. Go to File > Save, name it: Quick PDF Save.

🔧 Use It:

  • Right-click any document → go to Quick Actions > Quick PDF Save.
  • Your document will be printed to PDF automatically (you can customize the default location using advanced scripts).

🛠️ Optional: AppleScript for Advanced PDF Automation

You can also use AppleScript for specific app automation:

applescriptCopyEdittell application "Microsoft Word"
    open "Macintosh HD:Users:YourName:Documents:myfile.docx"
    save as active document file format format PDF file name "Macintosh HD:Users:YourName:Desktop:myfile.pdf"
    close active document saving no
end tell

Save this as an .app or run it from Script Editor.


✅ Summary

PlatformMethodBest For
WindowsBatch script or right-click shortcutOne-click PDF printing
macOSAutomator Quick ActionIntegrated PDF export
BothManual File > Save As PDFBuilt-in and reliable

PDF Converter Script Files

Contents:

  1. ConvertToPDF.bat – Windows batch script to auto-print Word files to PDF.
  2. ConvertToPDF.scpt – AppleScript to automate PDF saving in macOS (adjust paths accordingly).

On sale products