Replacing the Hyperice backend four weeks before launch

Hyperice’s HyperSmart app connects recovery devices with guided routines, activity data and personalised recommendations. Four weeks before launch, we took over its backend, rewrote it and launched on the original date, then kept building the product.

Used by

The Hyperice app open on a phone, beside a Hyperice massage gun
Industry
Connected devices & recovery technology
Engagement
Teams
Scope
Backend rewrite, migration, infrastructure, integrations, AI
Timeline
From 2023, 4 weeks to launch

The situation

Four weeks to replace a backend that could not scale

HyperSmart connects Hyperice’s recovery devices with guided routines, activity data and personalised recommendations. Its backend runs the accounts, integrations and recommendations behind the app.

We took the backend over four weeks before launch. Database queries were slow, the code had no coherent structure, the system crashed, and the architecture could not carry the traffic expected at launch. It also held the accounts of people already using an earlier Hyperice app.

Patching it would have kept the structure that caused those problems. We chose a full rewrite, delivered for the original launch date.

What we built

A new backend, and a migration users never saw

We rewrote the backend and the REST APIs behind the app and web clients in NestJS. The data model and indexes were redesigned around the queries the app actually made, with caching in Redis, and database response times fell from 1,200ms to 280ms.

Before go-live, k6 load tests modelled launch traffic against staging. The AWS infrastructure was defined in Terraform, with monitoring, alerting and runbooks in place for launch day.

The hardest part was the switch itself. Users of the earlier app had to move to the new backend without noticing. Both backends accepted the same session tokens, so anyone signed in on the old one stayed signed in on the new one. The switch took no downtime and signed nobody out.

The outcome

An on-time launch, then product development

HyperSmart launched on its original date. During the launch window the new backend carried more than 25,000 concurrent users at 99.8% uptime.

After launch we stayed on to build the product: integrations with Apple Health, Android Health, Strava, Garmin and Whoop, then AI longevity scoring and recovery recommendations delivered through notifications. The app has since grown to hundreds of thousands of monthly active users.

Outcomes

  • 4 weeks

    From backend takeover to launch

    On the original date, with no downtime during the migration

  • 25,000+

    Concurrent users supported at launch

    During the launch window, at 99.8% uptime

  • 77%

    Lower database response time

    From 1,200ms to 280ms

They took over our backend a month before launch and still shipped on time. I haven’t seen a team move that fast without breaking things. Concurrency went from a worry to a footnote, 25,000+ users at launch and the database never blinked.
Daniel K.CTO, recovery-tech brand

What we shipped

  • Full backend rewrite and REST APIs for the app and web clients
  • Data model, indexes and caching redesigned around real queries
  • User migration on shared session tokens: no downtime, no sign-outs
  • k6 load testing against expected launch traffic
  • AWS infrastructure in Terraform for staging and production
  • Monitoring, alerting and runbooks for launch and operations
  • Integrations with Apple Health, Android Health, Strava, Garmin and Whoop
  • AI longevity scoring and recovery recommendations via notifications

Built with

Back-end

  • NestJS
  • TypeScript
  • REST APIs

Data

  • PostgreSQL
  • Redis

Platform

  • AWS
  • Firebase
  • CircleCI
  • Docker
  • Terraform

Reliability

  • k6
  • Grafana

Other engagements, other constraints.

  • Blissbook on a laptop: a workplace-violence policy open in the editor, with its approval status, reviewers and discussion thread alongside

    Blissbook

    AI features and core product development for HR policies

  • The PrizePicks app on a phone resting on a basketball: NBA player cards, each with a points line to pick over or under

    PrizePicks

    Architecture and development for The Esports Lab

Tell us what you’re building.

The complex, the critical, the bold. We’ll tell you how we’d ship it.