Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

WOFF2 conversion from standard WOFF

Tags:

I've seen that some Google Webfonts now use WOFF 2.0. Can I somehow convert my existing WOFF-fonts to this new (and supposedly better format)? And how?

like image 481
Morten Hjort Avatar asked Apr 09 '14 09:04

Morten Hjort


People also ask

What is the difference between WOFF and WOFF2?

Web Open Font Format (WOFF): WOFF was developed in 2009 as a wrapper format for TrueType and OpenType fonts. It compresses the files and is supported by all modern browsers. Web Open Font Format 2 (WOFF2): WOFF2 is an update to the original WOFF format.

What format is WOFF2?

A WOFF2 file is a web font file created in the WOFF (Web Open Font Format) 2.0 format, an open format used to deliver webpage fonts on the fly. It is saved as a compressed container that supports TrueType (. TTF) and OpenType (. OTF) fonts.


1 Answers

Certainly! You can convert the existing woff files to the new format. You will get more than 30% improvement on the compression ratio.

Even though browser support is limited at this moment

http://caniuse.com/#feat=woff2

It will eventually change. You should use the @font-face fall back and start putting these kind of directives in your css now.

 @font-face {    font-family: MyFont;    src:        url('font.woff2') format('woff2'),        url('font.woff') format('woff');   } 

You can use the following tools to convert from ttf/woff to woff2.0

http://everythingfonts.com/woff-to-woff2

https://github.com/google/woff2

like image 81
dors Avatar answered Oct 05 '22 20:10

dors