Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

This is one of those things you simply don't expect to test when you're benchmarking performance. I've been trying to cut away chunks of 20-50ms on a side project I've been working on hosted on a .io domain, and I'm seriously considering switching because of this. Great article for sure. I also wonder at what point the trade off is between a vanity domain vs a more performant domain. For a CDN this makes perfect sense, but would it be better to launch with a less-notable url vs a more performant one?


> For a CDN this makes perfect sense

I'd say the inverse is more likely. If you're going to fire a single request to a domain only you are using and you're running a full local resolver, it may make a difference.

For a public CDN: your browser already has the file cached. If it doesn't then it has the domain cached. If it doesn't then the dhcp-provided resolver has it. If it doesn't, then at least it already has the TLD nameserver available immediately, and the TLD can serve that response from very hot cache. It's CDNs job to make sure this happens.


With a vanity domain, you can fully control the TTL values. All my sites use a vanity domain because it doesn't tie me to a particular CDN, and they have 86400 TTL.

When you have a vanity domain like cdn.example.com, the recursive resolver already knows the nameservers for example.com, so this actually reduces the additional DNS lookups.


I humbly suggest this is not a good use of your time.


nope I would kill to be able to cut 50ms by DNS tweaks across the large fleet >100 sites for a major brand


On the first request. All subsequent requests will be cached.

Oh, and if the requestor has a large DNS cache upstream, it's already done.

Oh, and if the browser used a pre-fetch, that's already done.

Oh, and if you have already invested your branding effort across 100 sites, maybe you don't want to re-do all that?

Oh, and if you need to cut 50ms from your first time page load, have you considered dropping all the trackers and analysis JS loads? Can you deliver your first page without any JS at all? Can you do it without a database lookup?

Those are all things you should do before killing anyone.


If you haven't done already, take a look at don't delivery improvements. Serve don't files locally, subset them, and use variable fonts and woff2. I'm a micro performance enthusiast myself and it's my #1 optimization with the biggest gain.


dont't ??

I will have a look at your font suggestions


Not if you like nerding out on this stuff. Then it's more like a hobby or pleasant diversion.

But I agree one needs to zoom out and put things into its proper perspective.


Switch to .dev then? It's not listed on this graph but its performance should be similar to .app.

Disclaimer: I run .dev.


Although I may see what the BunnyCDN is trying to get at, personally I've gotten under 10ms with .com (even w/o caching).

I find this a bit hard to believe without more people justifying or backing this work up.

So yeah, don't worry about your TLD. .io is perfectly fine and companies and people internationally use it.


.io doesn't have a good history though outside of this - https://hn.algolia.com/?query=io%20domain&sort=byPopularity&...



I'd like to point out that these are empty platitudes. Imagine going to your boss to justify not moving tlds and saying, "well sdan on hackernews said it was fine!"


if anyone does tell their boss, let me know ;) haha




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: