Windows

Add a One-Click Print to PDF Button in Microsoft Excel on Windows 11

Learn how to create a custom Print to PDF button in Microsoft Excel on Windows 11 so you can save spreadsheets as PDFs faster and with fewer clicks.

Andrew Miller
Andrew Miller
Technology Writer  •  Oct 22, 2026  •  4 min read

If you regularly save Excel workbooks as PDFs, a custom Print to PDF button can save time and reduce repetitive menu clicks. On Windows 11, you can add a one-click shortcut in Excel by using the Quick Access Toolbar and, if needed, a small macro-based workaround for more control.

This guide shows the simplest way to set up a PDF-printing button in Excel, along with a reliable alternative if you want the button to export a file automatically instead of opening the print dialog every time.

Add a One-Click Print to PDF Button in Microsoft Excel on Windows 11

The simplest way: add the built-in Print command to the Quick Access Toolbar

Excel already includes a Print command that works with the Microsoft Print to PDF printer in Windows 11. Adding that command to the Quick Access Toolbar gives you a much faster way to open printing without hunting through the File menu.

Advertisement
  1. Open Microsoft Excel.
  2. Click the small drop-down arrow on the Quick Access Toolbar at the top-left corner of the window.
  3. Choose More Commands.
  4. In the Choose commands from box, select All Commands or Commands Not in the Ribbon.
  5. Scroll down and select Print Preview and Print or simply Print, depending on the version of Excel you are using.
  6. Click Add, then click OK.

You should now see a Print button on the Quick Access Toolbar. When you click it, Excel opens the print view, where you can choose Microsoft Print to PDF as the printer.

Why It Matters This method is quick to set up and does not require macros, but it still involves a print screen and a save dialog. If you only want faster access to PDF printing, this is usually enough.

If you want a true one-click PDF export button

If your goal is to click a button and immediately create a PDF file, a macro is the better option. This method can export the active worksheet or workbook directly to a PDF without opening the full print interface.

Warning Macros can only run if macro security settings allow them. Also, be careful to save exported PDFs to a folder you can easily find, especially if you automate the filename.
  1. Press Alt + F11 to open the Visual Basic for Applications editor.
  2. In the VBA editor, click Insert, then Module.
  3. Paste a macro such as the following into the module window: Sub ExportActiveSheetToPDF() Dim filePath As String filePath = ThisWorkbook.Path & "\" & Left(ThisWorkbook.Name, InStrRev(ThisWorkbook.Name, ".") - 1) & ".pdf" ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:=filePath, Quality:=xlQualityStandard End Sub
  4. Close the VBA editor.
  5. Return to Excel and save the file as a macro-enabled workbook if needed.
  6. Add the macro to a button by using the Developer tab or by placing it on the Quick Access Toolbar.
Note This sample macro exports the active sheet to the same folder as the workbook and uses the workbook name as the PDF filename. You can adjust the path if you want files saved somewhere else.

Add the macro to a button in Excel

Once the macro exists, you can attach it to a button so it behaves like a custom Print to PDF shortcut.

  1. Right-click the Quick Access Toolbar and choose Customize Quick Access Toolbar.
  2. In the Choose commands from box, select Macros.
  3. Select the macro you created.
  4. Click Add, then click OK.

If you prefer an on-sheet button, you can also insert a Shape, right-click it, choose Assign Macro, and select your PDF export macro.

Quick Tip If you use the macro often, give it a short, clear name such as ExportPDF or SaveAsPDF so it is easy to recognize in the toolbar list.

Which method should you use?

Best For Users who regularly send reports, invoices, spreadsheets, or formatted tables as PDF files and want a faster workflow in Excel on Windows 11.

Things to check if the button does not work

Key Fact Microsoft Print to PDF is included with Windows 11, but Excel can only use it through the normal print workflow unless you create a macro or shortcut around that workflow.

A better workflow for frequent PDF exports

If you create PDFs from Excel often, the best setup is usually a combination of a clean print layout and a custom shortcut. Set your page size, margins, and scaling once, then use the toolbar button or macro each time you need a PDF. That gives you both speed and consistent output.

Topics

More from Windows

View all →
How to Fix DISM Error 0x800f0915 in Windows
Windows

How to Fix DISM Error 0x800f0915 in Windows

How to Fix Command Prompt When You Can’t Run It as Administrator
Windows

How to Fix Command Prompt When You Can’t Run It as Administrator

5 Ways to Fix HP Support Assistant When It Won’t Install
Windows

5 Ways to Fix HP Support Assistant When It Won’t Install

Why USB Devices Show Up as Unknown in Windows 11
Windows

Why USB Devices Show Up as Unknown in Windows 11

How to Fix the Windows Fast Startup Error 0xc00000d4
Windows

How to Fix the Windows Fast Startup Error 0xc00000d4

How to Fix a Volume Bar That Keeps Appearing in Windows
Windows

How to Fix a Volume Bar That Keeps Appearing in Windows