Fix .woff2 Font Errors in Browser in IIS

IIS 8.5 and below (IIS 10 MIME-types has support for .woff2) doesn't recognise .woff2 font files. This will cause an error in browser like this:

To fix this you need to add the following to your websites web.config file, which is located in the wwwroot folder.

<system.webServer>
  <staticContent>
	<remove fileExtension=".woff2" />
	<mimeMap fileExtension=".woff2" mimeType="font/woff2" />
  </staticContent>
</system.webServer>

Return to Category