Office 2007 Mime Types (for IIS)

Had some troubles with Office 2007 files not being downloadable on our windows servers … did a bit of Googling and found this nice list of Office 2007 mime-types:

.docm,application/vnd.ms-word.document.macroEnabled.12
.docx,application/vnd.openxmlformats-officedocument.wordprocessingml.document
.dotm,application/vnd.ms-word.template.macroEnabled.12
.dotx,application/vnd.openxmlformats-officedocument.wordprocessingml.template
.potm,application/vnd.ms-powerpoint.template.macroEnabled.12
.potx,application/vnd.openxmlformats-officedocument.presentationml.template
.ppam,application/vnd.ms-powerpoint.addin.macroEnabled.12
.ppsm,application/vnd.ms-powerpoint.slideshow.macroEnabled.12
.ppsx,application/vnd.openxmlformats-officedocument.presentationml.slideshow
.pptm,application/vnd.ms-powerpoint.presentation.macroEnabled.12
.pptx,application/vnd.openxmlformats-officedocument.presentationml.presentation
.xlam,application/vnd.ms-excel.addin.macroEnabled.12
.xlsb,application/vnd.ms-excel.sheet.binary.macroEnabled.12
.xlsm,application/vnd.ms-excel.sheet.macroEnabled.12
.xlsx,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
.xltm,application/vnd.ms-excel.template.macroEnabled.12
.xltx,application/vnd.openxmlformats-officedocument.spreadsheetml.template

Adding all mime-types to IIS in one step is very simple:

The easiest way to do this is stopping IIS and editing the metabase XML file (C:\WINDOWS\system32\inetsrv\MetaBase.xml) using a text editor. Search for the <IIsMimeMap Location="/LM/MimeMap" /> element and append the lines above to the MimeMap attribute

Published by Bramus!

Bramus is a frontend web developer from Belgium, working as a Chrome Developer Relations Engineer at Google. From the moment he discovered view-source at the age of 14 (way back in 1997), he fell in love with the web and has been tinkering with it ever since (more …)

Join the Conversation

25 Comments

  1. Excellent article! Thanks for the help.

    MIME types can be edited though IIS by right clicking on the webserver, selecting properties, then pressing the MIME type buttons. You will need to restart IIS after making the changes, this can be done by running “restartiis /noforce” from the start button, then run.

  2. I’m trying to do this on IIS 5.0 – WIN2K3 and there is no xml file, only C:\WINNT\system32\inetsrv\MetaBase.bin which is considerably less editable! When trying to do it through IIS, I’m clicking File Types in the HTTP Headers tab, Clicking New Type, putting “xslx” (tried .xslx too) into Associated extenion and “application/vnd.openxmlformats-officedocument.spreadsheetml.sheet” into Content type (MIME). Then restart IIS and nothing… any ideas anyone?

  3. This post helped me a lot. THANK YOU!!!

    I guess I also hate Spamtoo … That name sounds Italian … hmm … lol

  4. My problem is that, while HTTP response gets delivered correctly to the browser (encoding is preserved and file is CSV), Excel shows it as gibberish text. I don’t know why. I added these MIME types, but still no result.

Leave a comment

Leave a Reply to wadenick Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.