Include typical font files like ttf in the default mime.types

Maxim Dounin mdounin at
Mon Jan 2 23:49:35 UTC 2017


On Mon, Jan 02, 2017 at 04:06:15PM +0200, Otto Kekäläinen wrote:

> I noticed the default mime.types in Nginx does not include some very
> common assets, like ttf font files:
> I suggest the mime.types should be extended to include at least these:
>     application/x-font-ttf                ttf;
>     application/           otf;

As far as I can tell, both .ttf and .otf are handled fine when 
served as application/octet-stream.  Do you have any specific 
reasons to add these types?

Note that nginx doesn't try to maintain all the mime types known, 
but rather tries to supply types generally needed for a web 

> A fairly extensive and well tested list combiled by multiple people
> with HB5P authority can be viewed at:

Note the link suggested uses "font/otf" for OpenType fonts instead.

> I'd recommend adopting the full listing above to fix the font issues
> and probably many other issues in one go.

No, thanks.

Maxim Dounin

More information about the nginx-devel mailing list