Status widgets
Our paying customers asked for a way to show live service status on their own websites and portals, so their users would stop going back to the status page. I designed and built an embeddable web component and released it on a CDN in January 2021. Zoho and Site24x7 then adopted it in their own support and concierge portals.
- Role
- Design, product and front-end engineering, end to end
- Company
- Zoho, StatusIQ
- Period
- December 2020 to January 2021
- Scope
- Research, design, product decisions, build, release pipeline
A customer opens their status page in StatusIQ, chooses Share, picks a type, copies a generated snippet and pastes it into their page.
Context and my role
StatusIQ hosts status pages for companies that want to tell their users when a service is down. The widget was a Green-tier feature. No product manager worked on it, so I made the product decisions as well as the design and the build.
- Me
- Design direction, product decisions, the whole front end, the build and the release pipeline.
- Engineering manager
- Prepared the platform, including the public APIs the widget calls. Reviewed and tightened the scope of the first release.
- Support
- Shared the solution with customers.
- Pre-sales
- Pushed the feature in their proofs of concept.
The problem
The customers were banks, insurers and internet infrastructure companies, with large user bases, critical systems and SLAs that depend on being open about outages. Their users kept returning to the status page to check. The customers wanted the status where those users already were: public websites, support portals, and logged-in portals such as a bank's customer area.
Status could already be shared in several ways, and each fell short. RSS feeds, iCalendar and iframes took effort from the customer, or showed status only when someone asked for it or when we broadcast it. SMS and email notifications reached subscribers, but they sat on paid plans and were capped by the plan or its add-ons. A widget would let anyone see the status with no sign-in, using public APIs that already existed.
The requests came from early paid customers and from demos. Paying customers, each with their own reasons, asked for the same thing.
What I learned
I looked at Atlassian Statuspage, Status.io, FireHydrant and Freshstatus. Atlassian and Status.io already had a status widget, and Status.io's was built from native HTML elements. FireHydrant had none. Freshstatus added a status badge and a banner, which it calls an Alert Widget, by July 2021, after we had shipped. I also looked at the Site24x7 uptime button and GitHub-style badges, because I wanted to stay close to a look people already know while letting customers brand the widget.
Their current public docs show how differently each one handled it. These are today's docs, not what existed in 2020.
- Atlassian
- A coloured flag that appears only during an incident or maintenance. Maintenance shows 24 hours ahead. With several incidents it shows the most severe and a count of the others. Position and hex colours are set in the dashboard, and the snippet is pasted as the last item in the page body. Public pages only, and live updates need a paid subscription.
- Status.io
- One always-visible element: a coloured dot and the status text for the most severe component. The install is a snippet with a stylesheet, jQuery and a script in which you add your status page URL.
- Freshstatus
- A badge, and an Alert Widget that shows only during an incident or maintenance. A customer has to request access through a survey before they can create one.
- FireHydrant
- No widget.
- StatusIQ
- Three types. Basic and Badge are always on, and Sticky shows only when something is wrong. One generated snippet. Green tier only.
- Atlassian's flag and Freshstatus's Alert Widget show only when something is wrong. Status.io's dot is always on.
- Installing ranged from one pasted snippet to a snippet plus a library plus an edit to a script.
- Access was gated three ways: a paid subscription, a survey and a paid tier.
- A customer's brand colours and the status colours must never be confused.
Options I considered
- A top banner. I tried it and dropped it. Another feature already used the same style, and stacking several banners on one page was poor UX.
- An iframe. Site24x7's uptime button already worked like one. I dropped the idea because an iframe couldn't do what the widget needed. It can't resize to its content, so a one-line badge and a multi-line incident card need different heights, and it doesn't adapt to the host's layout on mobile. The host page's CSS can't reach inside it, so every colour or font would need its own option. A Sticky card can't float over the page from inside a frame. It is also a separate document, so it loads slower, sits outside the page's accessibility tree, and can be blocked by a site's framing rules.
- GitHub and NPM. I published the widget this way first. Customers needed too much technical knowledge to clone and install it, so I moved it to a CDN.
- Vanilla custom elements, SkateJS, Polymer, Angular 6 and React. I considered all of them for building it, and chose Stencil.
Decisions
Six choices shaped the widget. For each: what I faced, what I chose, why, and what it cost.
One overall signal, in three types
- Problem
- A widget on someone else's page has to say one thing clearly, and it can't take over their layout.
- Decision
- Basic and Badge show only the overall status. If several components are down, they show the most severe, because that is what a viewer needs to act on, and a major outage outranks maintenance. Sticky is a floating card that appears only during an incident, and for maintenance 24 hours ahead and during it. It shows a headline, when it was last updated and a link to the details, and it stays hidden while everything is operational.
- Why
- The widget gives the one signal that matters, and the details stay on the status page. I hard-coded the 24-hour lead, which I took to be the industry standard.
- Cost
- Customers can't choose which components appear, and there is no theme, size or language option.
A snippet on a CDN, not a package
- Problem
- I first published the widget on GitHub and as an NPM package. Customers had to clone and install it, which took too much technical knowledge.
- Decision
- I hosted the JavaScript and CSS on our CDN. Customers paste a generated snippet, with comments saying where each part goes, and attributes configure it for their status page, styling and position.
- Why
- Installing becomes one copy and paste, with nothing to build.
- Cost
- Customers' pages now depend on files we control. A version parameter on the script URLs, a unique hash from the build, pins each customer to the version they installed. We release only a few times a year, and we email customers so they can update the parameter. A snippet with no parameter always loads the latest.
<!-- include these scripts in the <head> section of your document -->
<script type="module" src=".../statusiq-status-widget.esm.js?VERSION"></script>
<script nomodule src=".../statusiq-status-widget.js?VERSION"></script>
<!-- include this webcomponent snippet at your preferred place -->
<statusiq-status-widget src="https://your-status-page-url" widget-type="basic"></statusiq-status-widget>
Stencil, with a browser line drawn from data
- Problem
- The widget had to run inside pages I don't control, without clashing with their styles, in the browsers customers' users really had. Enterprise users were still on IE 11 and the original Edge.
- Decision
- I built it with Stencil. Two things decided it. One build produced everything: NPM packages, a lazy-loading single-script CDN bundle, SSR hydration, TypeScript and JSX typings, and generated docs. And it shipped a CSS-variables shim for IE 11 and served modern or ES5 builds automatically, so customers set nothing up. Shadow DOM and uniquely named custom elements stop the widget clashing with the host page.
- Why
- I drew the support line from the user agents of requests to status pages at the edge. Browsers older than IE 11 were under 2% of daily users, so I didn't support them. IE 11 was above 5%, so I did. The original Edge wasn't Chromium yet, so it had to be supported too.
- Cost
- Polyfills. The first release shipped without them; after I found bugs in older browsers, I added them. The modern build is about 20 KB and the legacy build about 157 KB, roughly 83% of it polyfills. Supporting older engines also limited what I could try in the UI.
Brand colours and status colours stay apart
- Problem
- Customers want the widget to suit their brand, but if brand colours blur into status colours, a branded widget could be mistaken for a status signal.
- Decision
- Customers can set the position, the badge text and the colours of the sticky card's incident and maintenance states. The defaults follow severity. The widget's colours are also independent of the status page's own theme.
- Why
- The first reason was design: widget colours must not blur with brand colours. The second was technical: linking the two would have meant fetching the page theme from the database, which was possible if we had needed it.
- Cost
- Customers get less brand control than a full theme would give.
When the service is down, show nothing
- Problem
- What should the widget do when it can't reach the status service?
- Decision
- Nothing renders, and the browser console logs an error.
- Why
- The widget only shows non-operational states, so an error message on a customer's page would look like a disruption in their service, when the fault is in ours. It could only happen if our own service went down, and the 99.9% uptime SLA made that an edge case.
- Cost
- No visible fallback. The widget doesn't keep the last known state or retry.
A five-minute refresh, answered from a cache
- Problem
- Every widget on every customer page asks our servers for status, so a short refresh interval multiplies traffic quickly.
- Decision
- The refresh interval is five minutes at minimum. The widget checks response headers against our Redis cache, which updates when an incident's severity changes. If nothing has changed, the cache answers and the request never reaches our servers. The interval setting was in the code at launch but unsupported and undocumented, so I could see how much traffic we got first. I documented it after 14 days, once I understood how people used the widget.
- Why
- A shorter interval would only add requests that return the same answer.
- Cost
- The status a viewer sees can be up to five minutes behind.
What changed after launch
- Older browsers. I found bugs in them and added the polyfills.
- Refresh interval. I documented it 14 days after launch, once I knew the traffic.
- An SDK request. Some customers asked for the same thing in their mobile apps, and I designed the mobile adaptations of the same elements.
Impact
StatusIQ was a paid product, and the widget was a Green-tier feature. I don't have usage numbers and can't get them now, so what follows is what I saw, not what I measured.
- For customers
- Our paying customers asked for it. Support tickets came back positive, and it solved their problem. Observed.
- For the business
- It was Green-tier only from the start, because every widget view costs requests and it gave customers one more reason to move to a paid plan. Pre-sales pushed it in their proofs of concept. Zoho and Site24x7 adopted it in their own support and concierge portals. Observed.
- For the team
- Releases went through an internal build and release tool: build, internal QA, push to main and staging, then the CDN. I set up that pipeline myself.
- Not claimed
- Usage numbers, conversion or revenue. I didn't measure them, and I can't retrieve them now.
What I'd change, and what came next
- Open it up. I would open-source it, so people could modify the base code and build their own UI on the same core idea, beyond the three types I offered. A chat to support, real-time analytics and a "Report Issue" map could be built on it.
- Accessibility. I added the ARIA attributes and checked the default colours against contrast ratios. I didn't test customer-chosen colours, or how the widget looks to colour-blind users.
- Failure. If the widget can't fetch the status, it shows nothing and logs only a console error. That was deliberate. An error on a customer's page could make their visitors think the customer's site is broken, and the person who embedded the widget can read a console message and understand it. It tries again at the next refresh, every five minutes at the shortest, and rebuilds on every page load. I built nothing beyond that: no last known state to show in the meantime, and no faster retry.
The StatusIQ Mobile SDK was released after I left Zoho. A different team built it, adapting the same approach to mobile, and I had designed the mobile adaptations.