HomeProjectsAI FilesBlog

© 2026 Matheus Pires. All rights reserved.

Back to projects
Shift Chat

Shift Chat

A Slack-style internal communication platform built for hospitals and multi-facility operations, where staff rotate across shifts, wings, and sites.

TypeScriptNextJSReactWebSocketPostgreSQLRedis

Shift Chat: internal communication built for hospitals

Shift Chat is a real-time messaging platform for healthcare organizations that run multiple facilities. It borrows the interaction model people already know from Slack — channels, direct messages, threads, mentions, reactions — and rebuilds it around the way hospital teams actually work: in shifts, across wings, and rarely at a desk.

The premise is simple. Clinical and operational staff already communicate constantly, but they do it through hallway conversations, personal phones, and paper handoffs. Consumer messaging apps fill the gap by default, which is convenient and completely unsuitable for an environment where conversations touch patient care.

Facility is a first-class dimension

The core structural difference from a general-purpose chat tool is that every channel belongs to a facility. #General at Stanford Health Care and #General at UCSF Medical Center are different rooms, with different members and different histories — but a nurse manager who covers both sites sees them in one sidebar.

An All facilities switcher sits at the top of the navigation, letting staff either scope the workspace down to a single site or work across every facility they belong to. Channel rows and direct messages carry their facility inline, so there is never ambiguity about which site a message came from — the failure mode that makes a generic workspace unusable for a multi-site organization.

This also drives permissions. Membership in a facility determines what a person can see, and staff who move between sites gain and lose access as their assignments change, rather than accumulating permanent access to everywhere they have ever worked.

Designed around shift handoffs

The hardest problem in hospital communication is not sending a message — it is context transfer between people who are never online at the same time. Someone finishing a twelve-hour shift and someone starting one may overlap by minutes.

Shift Chat leans on a few deliberate choices for this:

  • Threads as the default for anything operational, so a request and its resolution stay in one readable unit instead of scattering across a channel.
  • A persistent new-messages marker, so a returning user resumes exactly where they stopped instead of scrolling to find their place.
  • Mentions that survive the shift, routing to whoever currently holds a role when the named person is off duty.

The result is that a channel reads as a continuous operational record, not a stream that only makes sense if you were watching it live.

Real-time architecture

The application is built with Next.js and React on the front end, with a WebSocket layer carrying messages, presence, typing indicators, and read state. PostgreSQL holds the durable record — facilities, channels, memberships, messages, and threads — while Redis handles fan-out across connected clients, presence tracking, and delivery coordination.

Message delivery is optimistic on the client and reconciled against the server record, so the interface stays responsive on the weak Wi-Fi that is normal inside a hospital building. Reconnection is treated as the expected case rather than an error path: clients resync missed messages on reattach instead of losing them.

Where it goes next

The natural extensions all follow from the facility model: on-call schedules that make mention routing automatic, role-based channels that populate from staffing systems, and retention policies configured per facility to match each organization's compliance posture.

Shift Chat is a familiar interface on top of an unfamiliar org chart — and that combination is what makes it adoptable by teams who do not have time to learn a new tool mid-shift.