Font-face throw a 404 error for woff files in Chrome

@font-face css rule use for stylish custom font instead of have to use one of the “web-safe” fonts.



font-family: myCustomFont;

src: url('webfont.eot'); /* IE9 Compat Modes */

src: url('webfont.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */

url('webfont.woff') format('woff'), /* Modern Browsers */

url('webfont.ttf')  format('truetype'), /* Safari, Android, iOS */

url('webfont.svg#svgFontName') format('svg'); /* Legacy iOS */


Now the myCustomFont is ready to use with any class, id or element of website, below is an example of how to use it for all div elements:

font-family: myCustomFont;

font face in css

Problem : @font-face rule throw 404 error for woff type file in Chrome And Mozila Browser with IIS server.

Solution :

add the MIME types in the web config:


Leave a Comment

Scroll to Top