Microsoft Publisher was retired in October 2026. Keep opening your .pub files on Mac, iPhone and iPad.

Guides · File types · Updated 16 November 2026

What is a .pub file? Publisher or SSH key

A .pub file is usually one of two things: a Microsoft Publisher document, or a plain-text public key for SSH and similar tools. The extension is shared, so the way to tell them apart is the file size, where it came from and what you see when you open it as text.

Download on the App Store

The two common meanings of .pub

In everyday office work, .pub is the extension of a Microsoft Publisher publication: a newsletter, flyer, brochure, programme or poster laid out with text boxes and images. It is a binary file made for Windows software.

In software development and server administration, .pub is conventionally the name given to a public key. When you generate an SSH key pair, the public half is saved with a .pub extension next to the private one. That file is a short line of plain text.

How to tell which one you have

  • Size: an SSH public key is a few hundred bytes to a couple of kilobytes. A Publisher file is normally much larger because it contains pages, fonts and pictures.
  • Origin: a file attached to an email from a club, school, church or business is almost certainly Publisher. A file next to another file of the same name without .pub, inside a hidden .ssh folder, is a key.
  • Open as text: a key begins with a word such as ssh-rsa or ssh-ed25519 and is readable. A Publisher file looks like unreadable symbols.

Do not paste the contents of an unknown file into a website. A public key is meant to be shared, but its private partner never is, and a Publisher document may contain private information.

Opening a Publisher .pub file

Publisher was only ever released for Windows. There has never been a Publisher for macOS, iOS or iPadOS, so a Mac shows a generic document icon and Quick Look has nothing to preview.

Microsoft has also retired Publisher. Its support notice gives 1 October 2026 for Microsoft 365 subscribers and 13 October 2026 for the perpetual version. Files do not disappear, but fewer people can open them.

On Apple devices you can read a compatible Publisher file in a third-party viewer. PubHarbor opens .pub files on iPhone, iPad and Mac, shows pages and compatibility warnings, and can export a searchable PDF or images in the paid version.

Opening a .pub public key

Any text editor opens a public key. On a Mac you can use TextEdit, or run cat on the file in Terminal. Its job is to be copied into a service such as a code host or a server authorized-keys list. Opening it as a document does nothing special, and PubHarbor is not the right tool for it.

Other places you may meet .pub

A few other programs have used the same three letters for unrelated formats, and old software packages occasionally ship files with it. If neither a Publisher viewer nor a text editor makes sense of the file, look at the surrounding folder, the email it came with and the sender's description. The program that created it is almost always named somewhere nearby.

When in doubt, do not rename the file or paste its contents anywhere. Copy it, and test the copy with a text editor for a public key or with a Publisher viewer for a document.

A short checklist before you spend time

  • Did it arrive from someone who makes brochures, newsletters or club materials? Treat it as Publisher.
  • Does it live in a .ssh folder or sit beside a private key? Treat it as an SSH key.
  • Is it tiny and readable in a text editor? It is a key, not a layout.
  • Is it megabytes in size and unreadable as text? It is a Publisher publication.

If a Publisher file will not open

First make sure it really is a Publisher file. A PDF or Word file renamed to .pub will not open, and neither will a file that is only a cloud placeholder and has not fully downloaded. Download it completely, then try again. Our guide on opening a PUB file on a Mac walks through the steps.

PubHarbor is a best-effort viewer and archive converter, not a Publisher editor, and it never changes the original file. An export is not a certified or pixel-exact copy, so compare anything important with a reference before relying on it.

Questions

Is a .pub file a virus?

The extension itself is not dangerous. As with any attachment, only open files from senders you know, and keep a copy of the original.

Which program makes .pub files?

Microsoft Publisher creates publication files. Separately, SSH tools such as ssh-keygen create public key files with the same extension.

Can a Mac open a Publisher .pub file?

Not by itself. macOS has no Publisher support, so you need a third-party viewer such as PubHarbor, or a PDF made from the original in Publisher.

Can I turn a .pub file into a PDF?

Yes, for Publisher files. Export from Publisher, or use a viewer that can export PDF. Public key files are text and are not converted.