I emailed IANA (Internet Assigned Numbers Authority) earlier today to ask about the new content on example.com. To my surprise, their VP replied. Here is the email: I am happy to try and answer any questions you have. The changes we make to the site from time-to-time are usually informed by a desire to either reduce the overall bandwidth demands of serving the site, or improve its utility. At its heart it is a placeholder...
As of right now, this is the response they serve. It’s 713 bytes (excluding HTTP headers):
$ curl example.com
<!doctype html><htmllang=en><head><metacharset=utf-8><linkrel=iconhref=data:,><metaname=viewportcontent="width=device-width,initial-scale=1"><title>Example Domain</title><style>html{color-scheme:light dark;background:light-dark(#eee,#222)}body{font:16px/1.6 system-ui,sans-serif;max-width:30em;min-height:100vh;margin:auto;padding:4.75em2em20vh;box-sizing:border-box;display:grid;place-content:center;text-align:center}</style></head><body><p>This domain is for use in documentation examples without needing permission. This is not a service, avoid relying on it for testing and monitoring purposes.</p><ahref=https://iana.org/help/example-domains>Learn more</a><scriptsrc=/s.js></script></body></html>
$ curl -s example.com | wc -c
713
If their primary objective is cutting bandwidth, then I’d suggest something like this (274 bytes after removing unnecessary whitespace):
<!doctype html><htmllang=en><head><metacharset=utf-8><linkrel=iconhref=data:,><metaname=viewportcontent="width=device-width,initial-scale=1"><title>Example Domain</title></head><body><ahref=https://iana.org/help/example-domains>Understand this page</a></body></html>
The link is already part of the page now, and all real users can just click it to understand the page; the information is all there already.
If you’re golfing minification, you can remove these parts without making it invalid or changing the meaning of anything (simplifying slightly, html, head and body start and end tags are optional, and the document is already declared UTF-8 in the content-type header and even if it weren’t it wouldn’t matter as the document doesn’t go beyond ASCII).
You can also drop the ,initial-scale=1 with no observable change in behaviour on realistic browsers. (It will only make a difference if one of the words in “Understand this page” is wider than the viewport, or on early iPhone browsers on rotate.)
Rebelling a little more, you could drop <htmllang=en>. Nothing will implicitly trust a declaration of English anyway because it’s been abused so much.
And <!doctype html> because who cares about quirks mode for something like that? And ", " and </a> because nominal validity really doesn’t matter.
<linkrel=iconhref=data:,><metaname=viewportcontent=width=device-width><title>Example Domain</title><ahref=https://iana.org/help/example-domains>Understand this page
As of right now, this is the response they serve. It’s 713 bytes (excluding HTTP headers):
$ curl example.com <!doctype html><html lang=en><head><meta charset=utf-8><link rel=icon href=data:,><meta name=viewport content="width=device-width,initial-scale=1"><title>Example Domain</title><style>html{color-scheme:light dark;background:light-dark(#eee,#222)}body{font:16px/1.6 system-ui,sans-serif;max-width:30em;min-height:100vh;margin:auto;padding:4.75em 2em 20vh;box-sizing:border-box;display:grid;place-content:center;text-align:center}</style></head><body><p>This domain is for use in documentation examples without needing permission. This is not a service, avoid relying on it for testing and monitoring purposes.</p><a href=https://iana.org/help/example-domains>Learn more</a><script src=/s.js></script></body></html> $ curl -s example.com | wc -c 713If their primary objective is cutting bandwidth, then I’d suggest something like this (274 bytes after removing unnecessary whitespace):
<!doctype html> <html lang=en> <head> <meta charset=utf-8> <link rel=icon href=data:,> <meta name=viewport content="width=device-width,initial-scale=1"> <title>Example Domain</title> </head> <body><a href=https://iana.org/help/example-domains>Understand this page</a></body> </html>The link is already part of the page now, and all real users can just click it to understand the page; the information is all there already.
score 1 · canonical
You’ve not counted the 2.15 kB of JS in
/s.jsthough.score 1 · canonical
The email this post is about addresses that.
score 1 · canonical
If you’re golfing minification, you can remove these parts without making it invalid or changing the meaning of anything (simplifying slightly,
html,headandbodystart and end tags are optional, and the document is already declared UTF-8 in thecontent-typeheader and even if it weren’t it wouldn’t matter as the document doesn’t go beyond ASCII).<head> <meta charset=utf-8> </head> <body> </body> </html>You can also drop the
,initial-scale=1with no observable change in behaviour on realistic browsers. (It will only make a difference if one of the words in “Understand this page” is wider than the viewport, or on early iPhone browsers on rotate.)You could also drop the
https:and write<a href=//iana.org/…>. From http://example.com, that’d make it a link to http://iana.org/help/example-domains rather thanhttps://…, but that doesn’t really matter.Rebelling a little more, you could drop
<html lang=en>. Nothing will implicitly trust a declaration of English anyway because it’s been abused so much.And
<!doctype html>because who cares about quirks mode for something like that? And","and</a>because nominal validity really doesn’t matter.<link rel=icon href=data:,> <meta name=viewport content=width=device-width> <title>Example Domain</title> <a href=https://iana.org/help/example-domains>Understand this pagescore 2 · canonical
Real nice! I kept the stuff at the start only because I copied the original page and removed everything I knew was unnecessary.
score 1 · canonical