Safari appending .EXE to the end of .PDF
HTTP Header: Content-Disposition

Have the server include an additional Content-Disposition header when serving the PDFs:

Content-Disposition: attachment; filename="&lt;MyPDF.pdf&gt;"


This provides the browser with a strong suggestion for the desired filename and suffix. See How to encode the filename parameter of Content-Disposition header in HTTP? for a discussion about limitations and implementing this feature.

MIME Type

Additionally, make sure the server's PDF mime type in the Content-Type: header is set correctly. There are variations in use. application/pdf is the recommended type.


  The standard MIME type is application/pdf. The assignment is defined in RFC 3778, The application/pdf Media Type, referenced from the MIME Media Types registry.


Test with curl

Use curl -I http://example.com/mypdf.pdf to test and ensure the correct headers are returned by your server. curl can provide credentials to work as a logged in user.

Potentially related question: When sending headers to download a PDF, Safari appends .html