New UI Pattern: Website Loading Bars
usabilitypost.com
usabilitypost.com
To get a smooth transition from page to page I use Backbone.js with pushState and Handlebars to do client-side rendering of various pages. This allows for nice subtle touches like the logo fading out when navigating to a package detail screen and the search bar animating position when switching from the homepage to the search page.
The thing that was missing was any sort of indicator that the page was loading. A progress spinner at least indicates some sort of activity, but can be relatively useless is knowing when something will complete.
To provide a better progress indicator, I used a combination of the XHR readyState value, plus the number of total bytes downloaded when in readyState 3 to set the width of a bar. I then used a CSS transition property on the width property to have the bar smoothly grow from one width to another.
Originally I had tried using JS to animate the width, but CSS transitions seem to do a much better job of creating a nice smooth animation. The downside is that IE8 and 9 aren't supported, but I just do full page refreshes with them anyway since they do not support pushState.
http://fiddle.jshell.net/zuBDW/2/show/
It doesn't load new content with ajax, nor does it pre-fetch. It just shows a website loading bar. I think this UI element is very nice. Especially for heavier pages, showing a website loading bar might combat users leaving, as something is happening.
For Ajax-loading I think it is a nice alternative for a center-center spinner.
The first version of this didn't have any kind of gloss, just 2 text inputs and a "go" button.
I showed it to some people I know and their immediate recommendation was to have some feedback to see how long things where taking. However, I didn't have any kind of a way to actually tell the user how things where going, so I took the next best approach: I fake it.
If you look at the source code, you'll see that when you press the "make a gif" button it starts loading the loading bar. That loading bar is totally useless, as it is entirely client side and shows no progress at all.
But people love it! Everyone I showed it to said it was a big improvement, making it nicer to use.
Even though it's a fake loading bar.
1. It lets you know that you clicked the go button correctly and that the computer isn't waiting for more input (perhaps you could disable the inputs as well).
2. It gives a user a reasonable expectation of how long the process should take i.e. it's not instant and they have to wait a bit.
Here is a video showing an indeterminate progress bar:
We use bootstrap already, but I wanted the user to feel a sense of progress, whereas the indeterminate ones merely give a sense of action.
The iOS Messages app has a SMS progress bar that is totally fake: its duration is actually the mean duration of the last time it took to send SMSes, and is made to fill up to ~80% in that duration. It takes advantage of the knowledge that the exact same task takes about the same time. So despite being fake, its progress statistically makes sense and gives valuable, quantitative feedback to the user.
[edit] Actually, doing a little testing on it now - position:fixed seems to just work. I like this solution a lot need to test it out... would be great to attach this to xhr progress events...
I can't wait for those to be useful everywhere.
Youtube videos already have their own bar, why is the rest of the page so bloated that it needs bar? All the thumbnails? Maybe it's time to stop loading so many by default. Too many widgets for comments, ratings, favorites, etc.? Again, time to cut down on all the widgets.
The problem is that you can never rely on a load being fast. If you trim the fat on the app side and get a pageload down to 100ms, it might load almost-instantly for you on a 100Mbit/s connection.
But it still won't for someone on a 768Kbit/s DSL connection. In that case, you can't just let them sit there for a second or two with no feedback. A loading indicator is necessary for those instances.
I agree that sites should trim the fat and make pages load as quickly as possible so that a loading bar isn't really necessary. But you have a) instances where you're not in control of load times, like when you're relying on an external API (like Facebook, for example) to return data, and b) even if your app is blazing fast, you're still subject to slow connections that necessitate a loading bar.
But the page itself should not necessitate a page wide loading bar. That's a design flaw. Your page is bloated. Even a 768Kbit DSL should be able to load the page itself rapidly. If you're beyond that just for the basic page itself then you've failed in your job as a designer/developer, IMHO.
And I've designed web apps that never actually send you to a different page (just update the DOM), and in my experience they are extremely fast. Even making many API calls retrieving tons of records to a very modest server. That design is not in and of itself a reason to have load bars.
It sort of puts paid to the idea of progress.
There's also a related "law": “What Andy giveth, Bill taketh away.”
I used to think this was true. For me, the perceived inflection point where perceived speed of software started improving was somewhere around 2008. This may be because I switched to a mac in 2006 and the releases around that era had a big performance focus.
I'd imagine that, until broadband becomes truly instant, you will have a need to ensure users that the page is still loading. A user's patience will never grow. It will only shrink. The least we can do is buy ourselves precious seconds by using a progress bar. It is the difference between "Your call is important to us, please hold" and "You are now 5th in line to be answered. Please hold." The illusion of progress goes a long way in fooling the user's brain into having just a smidge more patience.
Really, you don’t need Javascript to load a page of text.
I've seen blog sites whee an idiotic spinner comes up for a few seconds while something or other is "loading". Something or other that is ultimately going to show me some text.
You must be talking about every single blogspot.com site.
Loading bars are necessary, and they certainly aren't new. The browsers just need to be updated.
For browsers that also show a loading progress bar (like Safari), it could also allow the page to set a precent loaded value. XMLHttpRequest2 supports progress monitoring.
I found it infuriatingly annoying: it displayed at inappropriate times, when something was happening in the background but the user was not waiting.
Unfortunately this is not something that can be handled well by the browser.
Try it: http://www.newrepublic.com/article/114362/odds-clinton-dies-...
I often wonder how far an article really goes. A lot of the times there are tons of content below the article, or perhaps just a long commenting thread twice as long as the article itself (or, as stated, a multiple page article (which you don't know about in advance)). I often scroll down for the sole purpose of finding out how long the article is.
I really like the information the New Republic conveys (but I dislike having a bar on top like that).
Yep
Here's one such paper http://hfs.sagepub.com/content/25/3/279.short
A little superfluous, but I can dig it.
This behavior goes way back to software like Real Player (buffering...), Windows Installer (which would actually hit 100% and then reset to zero for another round), and is seen today on YouTube, Netflix, and the browser's own feedback bar.
Can you predict the next few seconds of network bandwidth? Do you know the relative times of content downloading versus parsing json and browser rendering for various clients? All these play into the feedback you're promising, and you don't really know.
Previously on HN https://news.ycombinator.com/item?id=5761898
YouTube seems to actually track loading progress with their bar.
Medium's uses CSS animations to create a sort of "ticker" effect that doesn't actually convey progress, but rather activity. Still, this is pretty cool.
I wouldn't call it a bad experience nor subtle however - at least not on mobile devices; I noticed the progress bar the first time I used the app and it never gets in the way.
Of course, it would be even better if websites could programmatically enable/disable the browser progress spinner, in much the same way we are now trusted to mess with the history API.
I was actually going to also have it display a toast-like "7 minutes [of reading] left" on the top left when you scroll a good amount.
Having a thing across the top is perpendicular and doesn't relate to the vertical structure of a scrolling page. You have change the vertical position of your eyes to see it in a context where vertical position is significant.
Edit: Keep in mind that as I'm reading the story, my eyes are nowhere near the top of the browser. If you want to give me context, the top of the page is not the best place to provide it. It does make for a cool demo though.
I whipped it up pretty quickly so if there are any issues or enhancement ideas feel free to post them on Github.
Neither Chrome nor Firefox (at least on Windows or Linux) have an implemented loading bar for showing a web site's progress. I cannot speak to Internet Explorer 8 or greater because I tend to avoid them at all costs (and my company's system only has 7).
Sidenote: The Amazon App Store app on Android does something similar. I've seen other apps do this as well but I can't think of them at the moment. Is this a design pattern we will see more of like the Ajax spinners of the Web 2.0 craze?
They can control their own code.
Not saying that websites should implement this, but companies aren't going to want to point to browsers being the problem. Every company wants to (try to) control their users' experiences, for better or worse.
Extra loading indicators may be nice, but I think that a native feel should come first.
https://news.ycombinator.com/item?id=6245244 http://jqueryajaxloadingbar.herokuapp.com
They changed the website look and feel, had to look up the release date of the video for which I first saw this UI pattern (Sixes last by Alias): 2005
Edit: site now: http://1stavemachine.com/
I hope you're missing a </sarc> tag there...
Edit: I'm referring to the reading progress bar concept, not to the loading status referenced in the original post.
For longer wait times, this becomes critical. 5 seconds with no feedback feels incredibly, ridiculously long. 5 seconds with feedback feels like completely reasonable. I sometimes use almost entirely fake progress bars which asymptotically approach full when I have no way to measure how long something will take. It's bizarre, but even knowing that the progress bar is fake, watching it fill up makes the time seem shorter than staring at a spinner.
Actually improving loading time is important, of course, but the ROI is tiny compared to basic user feedback.