11 ms·
Cool URIs don't change (1998)
- grenoire 5y agoWe've been thinking about link rot since then, and yet we're still letting it happen without much care. Kinda' sad, but at least we're resting on the shoulders of archive.org.
- ricardo81 5y agoSo much of it is unnecessary. Any stats on link rot in 2021? Last I remember it's something like 10% of all links every year.
- greyface- 5y agoThe original 1998 URL to this article was http, not https. It changed.
- sleepyhead 5y agoIt did not change. http is still served but if you are getting https it is due to hsts. Regardless; redirect != it changed
- chuckhoupt 5y agoNote that HTTP is also upgraded if the UA requests it with the Upgrade-Insecure-Requests header: $ curl -I -H 'Upgrade-Insecure-Requests: 1' 'http://www.w3.org/Provider/Style/URI.html' HTTP/1.1 307 Temporary Redirect location: https://www.w3.org/Provider/Style/URI.html vary: Upgrade-Insecure-Requests
- user3939382 5y agoIn the next 5-10 years the https:// https:// will be amp:// when Google completes its process of consuming the web like noface in Spirited Away.
- srmarm 5y agoFair point but I believe the article refers to URI's rather than URL's so they're still technically correct. Edit - I've just had a look and URI covers the lot so my bad
- ricardo81 5y ago$ curl -i 'http://www.w3.org/Provider/Style/URI.html http://www.w3.org/Provider/Style/URI.html' HTTP/1.1 200 OK date: Thu, 17 Jun 2021 10:18:14 GMT last-modified: Mon, 24 Feb 2014 23:09:53 GMT ...
- greyface- 5y ago$ curl -I 'https://www.w3.org/' HTTP/2 200 [...] strict-transport-security: max-age=15552000; includeSubdomains; preload content-security-policy: upgrade-insecure-requests
- detaro 5y agoThe original URL still works, that's the key.
- osobo 5y agoAh, the digital naiveté of the nineties. Nowadays, cool URLS get changed on purpose so you have to enter the platform through the front instead of bouncing off your destination.
- gary_0 5y agoAnd they get loaded down with query string fields for analytics. I kill those with https://github.com/ClearURLs/Addon https://github.com/ClearURLs/Addon
- toastal 5y agoI keep checking to see when this add-on will get approved to Firefox Android's anointed list
- pwdisswordfish8 5y agoGood thing I still keep the version pinned at 68!
- ronyclau 5y agoIf you are using Firefox Nightly, you can install arbitrary add-ons (though quite a number of them don't work due to UI difference, container doesn't work too) now after going though some steps: https://blog.mozilla.org/addons/2020/09/29/expanded-extension-support-in-firefox-for-android-nightly/ https://blog.mozilla.org/addons/2020/09/29/expanded-extensio...
- BeFlatXIII 5y agoI wonder if there is a similar extension that leaves in the UTM parameters but fills them with curse words and other sophomoric junk data.
- jraph 5y agoGood idea, but risky if not done right or not adopted by many people. You'd be increasing your specificity and therefore the ability to track you.
- mustardo 5y agoHa, tell that to anyone at *.microsoft.com I swear every link to a MS doc / MSDN site I have clicked 404s or goes to a home page
- mavhc 5y agoYesterday I found a link on a MS document that went via a protection.outlook.com redirect, and another link on the same page linked to itself
- vmateixeira 5y agoAnd Oracle as well. Good luck trying to find old software and/or documentation links that don't 404.
- marcosdumay 5y agoOld software? It's difficult enough to find documentation on the current Oracle database. You only get random versions through a search engine, and can neither navigate into a different one, nor replace the version on the URL and get to a functioning page. Also, you can't start from the top and try to follow the table of contents because it's completely different.
- ape4 5y agoThey can't conceive of anyone coming to a page from anywhere other than an internal recently generated page :(
- prepend 5y agoThis is just a trick to hide that the documentation is terrible and useless. If we get to a “this content doesn’t exist” then we think that there is an answer to our question, we just can’t find it. We eventually give up, blaming ourself for not finding it; instead of finding and getting something stupid and not useful.
- ketzu 5y ago> There are no reasons at all in theory for people to change URIs (or stop maintaining documents), but millions of reasons in practice. I am not convinced that some of the reasons are not theoretical as well. The article in general seems very dismissive of the practical reasons to change URIs, like listing only the 'easily dismissable' ones to begin with. > The solution is forethought - make sure you capture with every document its acceptable distribution, its creation date and ideally its expiry date. Keep this metadata. What to do with an expired document? Don't get me wrong, it's good to strive for long lasting URIs and good design of URIs is important, but overall I believe a good archiving solution is a better approach. It keeps the current namespaces cleaner and easier to maintain. (Maintaining changes in URI philosophy and organization over tens to hundreds of years sounds like a maintenance nightmare.) The archiving solution should have browser support: If a URI can not be resolved as desired, it could notify the user of existing historic versions.
- Symbiote 5y agoAn expired document can be removed, and a "410 Gone" response returned. This is clearer for the user, who can expect not to find the document elsewhere on the website.
- kijin 5y agoMany APIs use versioning to keep the current namespace clean while still supporting the old version. It goes like /v1/getPosts, /v2/post/get, etc. This might be argument in favor of preemptively adding another level of hierarchy to your URLs, so that when the time comes to move the entire site to a new backend, you can just proxy the entire /2019/ hierarchy to a compatibility layer. But who are we kidding, we live in a world where 12 months of support for a widely used framework is called "LTS". Nobody seems to care whether their domains will even resolve in 10 years.
- ketzu 5y ago> Many APIs use versioning to keep the current namespace clean while still supporting the old version. It goes like /v1/getPosts, /v2/post/get, etc. I think that is an important thing to do (as I agree desigining URIs is important!) I am just not sure it is reasonable, or even desireable, for them to be indefinately maintained. I am not sure what the right timeframe for deprecation would be either.
- jasode 5y ago>When you change a URI on your server, you can never completely tell who will have links to the old URI. [...] When someone follows a link and it breaks, they generally lose confidence in the owner of the server. With 2+ decades to look back on after this was written, it turns out the author was wrong about this. Web surfers often get 404 errors or invalid deep links get automatically redirected to the main landing page -- and people do not lose confidence in the site owner. Broken links to old NYTimes articles or Microsoft blog posts don't shake the public's confidence in those well-known companies. Link rot caused by companies reorganizing their web content is just accepted as a fact of life. This was the 2013 deep link I had to USA Treasury rates: http://www.treasurydirect.gov/RI/OFNtebnd http://www.treasurydirect.gov/RI/OFNtebnd ... and the link is broken now in 2021. I don't think that broken link shakes the public's confidence in the US government. Instead, people just use Google/Bing to find it.
- bartread 5y ago> and people do not lose confidence in the site owner. No, but some of us do get incredibly pissed off with them. It's unendingly tiresome to find that some piece of content has disappeared from the web, or been moved without a redirect. Often archive.org can help but there's plenty of stuff that's just ... gone. I don't necessarily run into this problem every day, but anything up to two or three times a week depending on what I'm looking for.
- gwoplock 5y agoI swear this happens every time I visit a form. Either the 1 image I need has been purged or every post links to some other dead form. I've had pretty bad luck with archive.org for these things.
- npteljes 5y agoI see this just as how ads are perceived to be annoying. People can complain all the time but this annoyance, or in this case distrust, just doesn't seem to affect anything.
- 5y ago
- Gametroleum 5y ago> What to leave out > [..] > File name extension. This is a very common one. "cgi", even ".html" is something which will change. You may not be using HTML for that page in 20 years time, but you might want today's links to it to still be valid. The canonical way of making links to the W3C site doesn't use the extension.(how?) And the page URL is [...]/URI.html
- usrusr 5y agoA page URL. I guess this could be considered the canonical example of hn not always linking to the coolest source?
- cpach 5y agoIt works fine without the suffix as well: https://www.w3.org/Provider/Style/URI https://www.w3.org/Provider/Style/URI
- japanuspus 5y agoAlthough there is no redirect, the proposed best practice URL also works: https://www.w3.org/Provider/Style/URI https://www.w3.org/Provider/Style/URI
- slver 5y ago> You may not be using HTML for that page in 20 years time Yes it might be all Flash.
- yoursunny 5y agoSince I switched from ASP to PHP (2008), I avoided file extensions in page URI in most cases, and instead placed every page into its own folder. This is compatible with every web server without using rewrite rules. When I switched from PHP to static generators (2017), most URIs continued working without redirects.
- ketozhang 5y agoTo be fair, it's the OP that chose to use the URL with the extension. However, you could say WC3 could've disable their servers from automatically creating URLs with file extension if they wanted to follow this. 1. https://www.w3.org/Provider/Style/URI https://www.w3.org/Provider/Style/URI works 2. If https://www.w3.org/Provider/Style/URI.html https://www.w3.org/Provider/Style/URI.html is ever 404 then you get a very useful 300 page (e.g., try https://www.w3.org/Provider/Style/URI.foobar https://www.w3.org/Provider/Style/URI.foobar) 3. However, from (2) you can see Spanish page is encoded as `.../URL.html.es` which is bad because `.../URI.es` does not exist
- thomond 5y agoInterestingly the National Science Foundation URLs they used as examples of URLs that probably won't work in a few years all still work.
- tiew9Vii 5y agoThis is a recommended read on the subject "Designing a URL structure for BBC programmes" https://smethur.st/posts/176135860 https://smethur.st/posts/176135860. Clean user friendly urls are often at odds with persistent urls because of the information you can't keep in a url for it to be truly persistent.
- selfhoster11 5y agoIt's easy to put a reverse proxy in front of your service to translate old permanent URLs into whatever you're running currently. It's a table of redirects, and perhaps a large one, but it doesn't require a lot of logic to handle.
- alistairjcbrown 5y agoJeremy Keith's 11 year long bet against cool URLs (specifically on longbets.org) comes up next year -- and it looks like he might lose it https://longbets.org/601/ https://longbets.org/601/
- perilunar 5y agoLooks like he will lose the bet. Interestingly though, the original URL was: http://www.longbets.org/601 http://www.longbets.org/601
- yoursunny 5y agoI opened my website in 2006. Since 2009, I've kept all the links unchanged or redirected through two rebuilds. It's a lot of work because I need to customize URI structure in blog systems and put complex rewrite rules. To ensure the setup is more or less correct, I have a bash script that tests the redirects via curl. https://bitbucket.org/yoursunny/yoursunny-website/src/912f255e13a9802f023a6fc477ddbde594709668/http-server/test-redirects.sh https://bitbucket.org/yoursunny/yoursunny-website/src/912f25...
- slver 5y agoI've a bunch of small sites whose links end in ".php" despite they no longer run on PHP.
- smhenderson 5y agoI'm not sure if they still use it but a site I redid for a company many moons ago in Perl had Apache set to treat .htm files as CGI scripts so we didn't have to change the previous, static site's URL's. The original site ran on IIS and was old enough that MS software at the time still used three letter extensions for backwards compatibility, around 1997-1998 IIRC.
- JadeNB 5y ago> I've a bunch of small sites whose links end in ".php" despite they no longer run on PHP. Kudos for maintaining that compatibility, but it seems that this kind of thing is addressed in the linked document: > File name extension. This is a very common one. "cgi", even ".html" is something which will change. You may not be using HTML for that page in 20 years time, but you might want today's links to it to still be valid. The canonical way of making links to the W3C site doesn't use the extension.
- slver 5y agoBack then we didn’t have routers
- whirlwin 5y agoMy experience is that most developers don't even check the access logs to see what impact removing/changing an endpoint will have. Access logs are underrated. It is not some legacy concept. It is supported my all new platforms as well, including various Kubernetes setups.
- franze 5y agoThis is my battle-proven (tired and true) checklist for what I call targeted pages. (Pages that are entry pages for users, mostly via organic Google traffic) https://www.dropbox.com/s/zfwd331ehrucgw4/targeted-page-checklist.pdf?dl=0 https://www.dropbox.com/s/zfwd331ehrucgw4/targeted-page-chec... And these are the URL rules I use. Whenever I make any compromise on them or change the priority, I regret it down the road. Nr 1 and nr 2 are directly taken form the OP article. URL-rules - URL-rule 1: unique (1 URL == 1 resource, 1 resource == 1 URL) - URL-rule 2: permanent (they do not change, no dependencies to anything) - URL-rule 3: manageable (equals measurable, 1 logic per site section, no complicated exceptions, no exceptions) - URL-rule 4: easily scalable logic - URL-rule 5: short - URL-rule 6: with a variation (partial) of the targeted phrase (optional) URL-rule 1 is more important than 1 to 6 combined, URL-rule 2 is more important than 2 to 6 combines, ... URL-rule 5 and 6 are always a trade-of. Nr 6. is optional. A truly search optimized URL must fulfill all URL-rules.
- tosser0001 5y agoI recall it was almost axiomatic that the more expensive the content management system, the worse the URLs it produced. I completely believe in the spirit of TBL's statement, and wish the internet had evolved to followed some of the ideals implicit there in. I recall that people took some pride in the formatting of their HTML so that "view source" showed a definite structure as if the creator was crafting something. Now for the most part, URLs are often opaque and "view source" shows nothing but a bunch of links to impenetrable java script. I actually wonder when "view source" is going to be removed from the standard right-click window as it barely has meaning to the average user any more.
- londons_explore 5y agoPerhaps 'view source' should link to the authors github, highlighting the repo that can be built to produce the page. If the repo can't reproduce the contents of the page, simply treat that as an error and don't render the page.
- pc86 5y agoYes because all code is available via GitHub.
- londons_explore 5y ago(or other code repo)
- jefftk 5y agoIf you actually want to do this, you could have the browser check for source maps, and refuse to render any pages that did not provide them: https://developer.mozilla.org/en-US/docs/Tools/Debugger/How_to/Use_a_source_map https://developer.mozilla.org/en-US/docs/Tools/Debugger/How_... (Of course most pages are not willing to make their raw source available, so you would see a lot of errors.)
- 5y ago
- juloo 5y agoOne of the things that hype me about IPFS is that URIs can't change. Resources are immutable and the URI is only the hash of the content. https://ipfs.io/ https://ipfs.io/
- superkuh 5y agoTell it to Tor. They are destroying every URI created, indexed, known, and used over the last 15 years on Oct 15th, https://blog.torproject.org/v2-deprecation-timeline https://blog.torproject.org/v2-deprecation-timeline . Because of this indieweb has refused to add tor onion service domain support for identity.
- ______- 5y agoOnionland people had plenty of warning though. My old v2 Onion bookmarks are all discarded. The new V3 addresses are a good indicator of which .onion operators are serious and want to stay online no matter what.
- superkuh 5y agoI consider myself pretty active on tor. I've hosted a number of services for a decade. While I heard about the new Tor v3 services a long time ago I didn't hear about Tor v2 support being completely removed until April 2021. It was quite a shock.
- lolive 5y agoI did a small script to go through my past tweets. An awful lot of the links I mentionned in them DO NOT WORK anymore. Such a pity.
- graiz 5y agoIronically this was linked to with the .htm extension link but it was nice to discover that the non-page specific URI also worked on this site: https://www.w3.org/Provider/Style/URI https://www.w3.org/Provider/Style/URI
- diveanon 5y agoCool URIs now return a 200, redirect you to index.html, and then show a 404 page.
- brigandish 5y agoI'm still not sure why Tag-URI[1] hasn't gained more support: > The tag algorithm lets people mint — create — identifiers that no one else using the same algorithm could ever mint. It is simple enough to do in your head, and the resulting identifiers can be easy to read, write, and remember. They would seem to solve at least part of the problem Berners-Lee opined about: > Now here is one I can sympathize with. I agree entirely. What you need to do is to have the web server look up a persistent URI in an instant and return the file, wherever your current crazy file system has it stored away at the moment. You would like to be able to store the URI in the file as a check… > You need to be able to change things like ownership, access, archive level security level, and so on, of a document in the URI space without changing the URI. > Make a database which maps document URN to current filename, and let the web server use that to actually retrieve files. Not a bad idea, if you have a good URI scheme to back it up. I even wrote a Ruby library for it[2] (there are others[3][4] but no Javascript one that I can find, it being the language that produces the worst URLs and doesn't seem to have a community that cares about anything that happened last week, let alone 20 years ago, that's not a surprise) [1] http://taguri.org/ http://taguri.org/ [2] https://github.com/yb66/tag-uri/ https://github.com/yb66/tag-uri/ [3] https://gitlab.com/KitaitiMakoto/uri-tag/ https://gitlab.com/KitaitiMakoto/uri-tag/ [4] https://metacpan.org/pod/URI::tag https://metacpan.org/pod/URI::tag
- crazygringo 5y agoAt the end of the day, it's simply an unrealistic expectation that URIs don't change. And declaring for 20+ years that this isn't "cool" isn't going to change a thing about it... The web is dynamic, not static. Sites come and go, pages come and go, content gets moved and updated and reorganized and recombined. And that's a good thing. If content has moved, you can often use Google to figure out the new location. And if you want history, that's what we fortunately have archive.org for. For any website owner, ultimately it's just a cost-benefit calculation. Maintaining old URIs winds up introducing a major cost at some point (usually as part of a tech stack migration), and at some point benefits from that traffic isn't worth it anymore. There's no purist, moral, or ethical necessity to maintain URIs in perpetuity. But in reality, because website owners want the traffic and don't want to disrupt search results, they maintain them most of the time. That's good enough for me.
- rimliu 5y agoIt is very sad that this "cost-benefit" calculation ends up ruining the web. Devs too lazy to learn the basics and doing everything with React and a gazzilion of libs, nobody caring about accessibility, nobody caring about the url structure. It is very possible to go through 50 CMSes and still keep the URLS intact. Just that we forgot the users and UX moved away giving up the place for the DX. I still hope for the new web standards revoliution. Zeldmans of XXI century, where are you?
- prepend 5y ago> it's simply an unrealistic expectation that URIs don't change. I disagree. If I generate urls systematically, then when I change the scheme I can easily send a 302 with the new url. It’s also not hard to just keep a mapping table with old and new. I think that it’s lazy programmers who can’t handle it. Or chaotic content creators. I’ve had many conversations with SharePoint people who frequently change urls by renaming files and then just expect everyone linking to it to change their links. They seem to design content without ever linking because links break so much. It’s the damndest thing as it makes content hard to link to and reuse. People are too young to even care about links and stuff. Of course if SharePoint search didn’t suck it wouldn’t be as much of an issue.
- dang 5y agoPast related threads: Cool URIs Don't Change (1998) - https://news.ycombinator.com/item?id=23865484 https://news.ycombinator.com/item?id=23865484 - July 2020 (154 comments) Cool URIs Don't Change - https://news.ycombinator.com/item?id=21720496 https://news.ycombinator.com/item?id=21720496 - Dec 2019 (2 comments) Cool URIs don't change. (1998) - https://news.ycombinator.com/item?id=21151174 https://news.ycombinator.com/item?id=21151174 - Oct 2019 (1 comment) Cool URIs don't change (1998) - https://news.ycombinator.com/item?id=11712449 https://news.ycombinator.com/item?id=11712449 - May 2016 (122 comments) Cool URIs don't change. - https://news.ycombinator.com/item?id=4154927 https://news.ycombinator.com/item?id=4154927 - June 2012 (84 comments) Tim Berners-Lee: Cool URIs don't change (1998) - https://news.ycombinator.com/item?id=2492566 https://news.ycombinator.com/item?id=2492566 - April 2011 (25 comments) Cool URIs Don't Change - https://news.ycombinator.com/item?id=1472611 https://news.ycombinator.com/item?id=1472611 - June 2010 (1 comment) Cool URIs Don't change - https://news.ycombinator.com/item?id=175199 https://news.ycombinator.com/item?id=175199 - April 2008 (9 comments)
- ChrisArchitect 5y agotomte, why do you keep resubmitting these old things over? Recent discussion on this one's last submission was not even a year ago
- slaymaker1907 5y agoSometimes I think that immutability should have been a built in part of the web that way we wouldn't be so reliant on archivers like the Internet Archive. Someone still needs to store it, but it really shouldn't have been foisted onto one organization.
- beders 5y agoI bet you not even 50% of your bookmarks are still working. It is a shame.
- bofh23 5y agoWhy do webmasters and web developers neglect the title element? To mitigate link rot I share URLs along with the title and a snippet from the page. A good title can act as an effective search key to find the page at its new URL even if the domain has changed. Unfortunately, a lot of web pages have useless titles. Often sites use the same title on every page even when pages have subjects that are obvious choices for inclusion in the title (make, model & part # or article title that appears in the body element but not in the title). With the rise of social media, lots of pages now have OpenGraph metadata (e.g. og:title) set but don’t propagate that to the regular page title. Page titles are used by search engines and by browsers to set window, tab, and bookmark titles. Again, why do webmasters and web developers neglect the title element?
- kevinslin 5y agoUrls are the foundation of the internet and it always makes me sad when navigating to a page results in a 404 instead. On a somewhat related sidenote, this is why I created a note taking tool that publishes *permanent urls* - because your notes can change but your links shouldn't :) https://wiki.dendron.so/notes/2fe96d3a-dcf9-409b-8a09-fdaa5a664433.html#permanent-ids https://wiki.dendron.so/notes/2fe96d3a-dcf9-409b-8a09-fdaa5a...