Live data from Hacker News

Self-host your fonts for better performance

wicki.io

181–190 of 417 posts

Re: Self-host your fonts for better performance

#181

Maybe I'm being naïve, but why don't browsers ship with more popular fonts bundled to avoid problems like these? I have no issue with any of my browsers taking up fractionally more space for an extensive cache of the most popular web fonts when the payoff is better performance on so many sites. Of course, servers should still be capable of serving the fonts that the client requires to render the content correctly, bu…

I'm not an expert but: - 1. Copyright (though many fonts are free, true) - 2. Everyone uses a different font (just like everyone uses a slightly different version jquery) so cache hit would be pretty small IMO. Do you really want a browser to be gigabytes large? Especially on mobile it's not viable Maybe if browsers standardized on shipping, say, 20 carefully chosen fonts (not necessarily the most popular ones, just…

I believe already there but maybe a set of categories of fonts like UI, sans, monospace, handwriting could be alias usual for all websites and apps

Re: Self-host your fonts for better performance

#182

Earlier quoted context omitted.

MacOS makes text blurry. You need a high resolution monitor for macOS font rendering to be acceptable.

Like the one that comes with my laptop or is sold by apple? I think macOS will always be optimised for the best experience. Even if that means sub par XP if you don’t go all in on money. I’d actually be interested in learning more about the rendering vs say windows if you have a source.

> I think macOS will always be optimised for the best experience.

It is probably better to say that Apple will design for their intended market. I was using Apple products long before HiDPI was a thing and was never particularly happy with the fuzzy fonts under Mac OS X. While that may be acceptable when designing for print, since accuracy is more important, it is an annoyance in many other circumstances.

Re: Self-host your fonts for better performance

#183

Earlier quoted context omitted.

I've always thought the same. I see the same web fonts being used time and time again. It just makes sense for browsers to have an intelligent "permanent cache" - not based on your specific history but a common set of frequently sourced fonts, libraries, etc. This would be especially helpful now that shared caches are going away. One other option is to actually install the font into your OS. Any correctly-coded websi…

> Any correctly-coded website will try a local source first, which should help a lot for poor connections. Then Google Fonts is not correctly coded, as it'll use remote font only. And myriads of websites reusing Google Fonts snippets. To try local source first, you have to explicitly ask for it in @font-face/src which Google Fonts does not do. So installing font into your OS won't help you with any website using Goog…

I wasn't aware Google Fonts' CSS didn't include local. That's disappointing. Thanks for letting me know!

Re: Self-host your fonts for better performance

#185
post #151

Earlier quoted context omitted.

You’re underestimating how much work and skill it takes to make a good font, even for a great designer, so type foundries like to lock good fonts up behind rent-seeking license agreements.

How is charging for a font rent seeking?

It isn’t :)

Re: Self-host your fonts for better performance

#186

Earlier quoted context omitted.

I mean I’ve said it before but shipping like 20 (montserrat, raleway, open sans, etc) would cover most websites who use Google Fonts.

You might be right, but the next question is fashion. Will the same fonts be used still in 5 years, or (more likely) the new hotness will arrive? Should the browsers update the list each year? Then some fonts that were available will suddenly be not? Not so great. Web standards and browser features are generally built for the long term and backward compatibility. I mean, it's not impossible to find a solution, but it…

When you control 70% of the desktop market share, and you are releasing an evergreen browser that updates weekly, if not more frequently, any argument about not being able to stay on top of changes in the environment become rather silly.

Re: Self-host your fonts for better performance

#187

Maybe I'm being naïve, but why don't browsers ship with more popular fonts bundled to avoid problems like these? I have no issue with any of my browsers taking up fractionally more space for an extensive cache of the most popular web fonts when the payoff is better performance on so many sites. Of course, servers should still be capable of serving the fonts that the client requires to render the content correctly, bu…

I'm not an expert but: - 1. Copyright (though many fonts are free, true) - 2. Everyone uses a different font (just like everyone uses a slightly different version jquery) so cache hit would be pretty small IMO. Do you really want a browser to be gigabytes large? Especially on mobile it's not viable Maybe if browsers standardized on shipping, say, 20 carefully chosen fonts (not necessarily the most popular ones, just…

> "Do you really want a browser to be gigabytes large? Especially on mobile it's not viable"

Absolutely, i would rather give the browser 50 GB even on my phone over paying my mobile operator for downloading the same data over and over again.

And it wouldn't take anywhere near that much, I am sure 80% of most used fonts are only a couple dozen, that wouldn't tale gigabytes

Re: Self-host your fonts for better performance

#188

Earlier quoted context omitted.

I mean I’ve said it before but shipping like 20 (montserrat, raleway, open sans, etc) would cover most websites who use Google Fonts.

You might be right, but the next question is fashion. Will the same fonts be used still in 5 years, or (more likely) the new hotness will arrive? Should the browsers update the list each year? Then some fonts that were available will suddenly be not? Not so great. Web standards and browser features are generally built for the long term and backward compatibility. I mean, it's not impossible to find a solution, but it…

We keep root ssl certificates up to date, surely we can handle a few fonts.

Re: Self-host your fonts for better performance

#189
post #5

I'm usually the first one to sneer in disbelief at super users who 'go nuclear' and disable the likes of javascript and images when browsing the web, but lately, I've been experimenting with having custom fonts disabled (that is, fonts I don't have locally), and it feels to me that page loads are much faster, and in some case more readable (pages feel 'cleaner'?). The only issues I've come across so far is when a sit…

A well-designed web page does not rely on custom fonts, unless it is necessary to render a non-standard script.

Tufte would disagree, and at least some consider his thoughts on design to be very solid.

Would you be amenable to "A well-designed web page does not need to rely on custom fonts, provided their impact on page load is absolutely minimal"?

You can unobtrusively serve up a single font embedded as base64 on a static site - a world of difference from some of these sites that load up 5MB of a UX person's vision off some remote CDN.

Re: Self-host your fonts for better performance

#190
Shameless plug for two related articles, one about the privacy problems with Google Fonts and the other about self-hosting them (especially if they're variable fonts):

- https://brycewray.com/posts/2020/08/google-fonts-privacy/

- https://brycewray.com/posts/2020/08/good-stuff-without-googl...

Post reply on HN