Why we went serverless to revolutionize benefits at Nayya

Jordan Clark
January 15, 2025

Most people don’t picture cutting-edge technology or groundbreaking architecture when they think about benefits systems. But at Nayya, we’re on a mission to transform how people navigate health and wealth decisions, and that requires a platform that’s as dynamic and forward-thinking as our vision.

As we began building our next-generation benefits platform, we faced a critical decision: stick with the traditional “serverful” infrastructure or embrace the increasingly popular serverless architecture. The choice wasn’t easy, but ultimately, we opted for serverless—and it’s shaping up to be a game-changer.

Here’s why we went serverless, what it means for the future of benefits technology, and why this decision is about so much more than just cutting costs.

The Problem: Spikes, Lulls, and Everything in Between

Imagine you’re planning a massive event like a music festival. Most of the time, you only need a few staffers to handle ticket sales and inquiries. Still, as the event gets closer, your needs explode: ticketing systems get overwhelmed, customer support lines buzz nonstop, and thousands of people flood your website.

This ebb and flow of demand isn’t just a festival problem—it’s precisely what happens in benefits enrollment. During open enrollment periods, traffic surges as employees rush to select their health plans and voluntary benefits. Then, once the dust settles, the system sees only a trickle of activity.

Traditional infrastructure can’t keep up with this dynamic. Either you overpay for servers that sit idle most of the year or risk under-preparing for peak times, leaving users frustrated. We wanted something smarter, more adaptive, and more efficient. Enter serverless architecture.

Why Serverless? A Decision Rooted in Strategy

Choosing serverless wasn’t about jumping on the latest tech trend but aligning our architecture with our mission to deliver a modern, intuitive benefits experience. Here’s why serverless stood out:

  1. Cost Efficiency: Smarter Spending, Bigger Savings
    With serverless, you only pay for what you use. For us, that’s huge. During quiet periods, like mid-year, our costs shrink to reflect the lower activity. When open enrollment hits, the system scales up automatically, handling surges without breaking a sweat—or our budget. Traditional setups would have required us to over-provision servers year-round to prepare for those few busy months. That’s not just inefficient—it’s wasteful.
  2. Automatic Scaling: Always Ready for the Rush
    Open enrollment is like Black Friday for benefits. Traffic spikes are inevitable, but serverless lets us handle them seamlessly. Instead of manually adjusting capacity or worrying about crashes, the system scales on demand, freeing our team to focus on creating features users love.
  3. Flexibility for Diverse Workflows
    Our platform isn’t just a one-trick pony. It supports event-driven workflows (like notifications when your benefits card ships) and API-based workflows (like fetching plan details in real-time). Serverless handles both easily, allowing us to reuse logic and simplify development.
  4. Less Infrastructure Management: More Innovation
    Engineers want to solve problems, not babysit servers. Serverless offloads much of the infrastructure management to the cloud provider, letting our team concentrate on designing, coding, and iterating—not worrying about uptime or scaling.

Serverless vs. Serverful: It’s Not Even Close

Here’s a quick side-by-side comparison that helped cement our decision:

The Cost Story: Dollars and Sense

Let’s talk numbers. In our analysis, using AWS Lambda (a serverless solution) for daily operations costs nearly 50% less than a traditional serverful approach. Those savings aren’t just nice-to-have—they’re transformative. They free us to reinvest in features that make the benefits experience more intuitive, personalized, and impactful for users.

Overcoming Serverless Challenges

Of course, serverless isn’t perfect. Here’s how we’re tackling its limitations:

  • Cold Starts: Imagine calling a friend and waiting a few seconds for their phone to ring—that’s a “cold start.” When serverless functions sit idle, they take a moment to “wake up.” While this delay is minor (just milliseconds), we optimize our code and monitor usage patterns to keep performance smooth.
  • Execution Time Limits: Serverless functions have limits (e.g., 15 minutes on AWS Lambda), so for longer-running tasks, we’re using tools like step functions to split workflows into manageable chunks.
  • Statelessness: Serverless functions don’t “remember” anything between executions, which adds complexity for tasks that require state. To address this, we’re leveraging external databases and storage solutions to handle state-heavy workflows.

A Bold Step Forward

By choosing serverless, we’re not just building a better benefits platform—we’re rethinking what benefits technology can do. It’s about more than saving money or scaling seamlessly; it’s about creating a system that’s responsive, resilient, and ready to evolve alongside the needs of employees and employers alike.

This decision aligns with everything we stand for at Nayya: reducing friction, driving innovation, and delivering real value. As we continue to push the boundaries of what’s possible in benefits technology, serverless architecture is helping us lead the way.

So the next time you think about benefits, don’t picture something dull or complicated. Think of something smart, streamlined, and future-ready. That’s where we’re headed—and we’re just getting started.