Background gradient
hero image showing both graphite and shopify logos

When Shopify began consolidating its code into a single monolithic repository (monorepo), the Developer Infrastructure team faced a challenge: How do you keep developer velocity high as complexity grows? For Henrique Andrade, Principal Engineer at Shopify, the answer started to take shape before he even joined Shopify.

When he was prepping for Shopify interviews, he was looking up how to stack development using Git. “The only answer that I got was Graphite,” Henrique recalls. That early curiosity eventually led to a broader cultural shift in how Shopify engineers write and review code in their monorepo today. By adopting Graphite’s stacked pull request workflow, the team has transformed code review from a bottleneck into a building block of their engineering culture. 

Shopify saw a 33% increase in PRs shipped per developer since adopting Graphite.

Henrique first encountered stacked PRs (also called diffs) while working at Meta. The concept was simple: break large changes into small, reviewable chunks that build on each other. Meta had its own tooling, Phabricator, to support this workflow. After leaving Facebook, he felt firsthand how much easier stacking could be with the right tooling—and how much harder it was without it. 

Soon after joining Shopify, Henrique floated Graphite to a fellow principal engineer. “He told me, ‘I think Tobi [Shopify’s CEO] already knows about Graphite.’ And that’s how this all started.” What began as a small trial quickly scaled. “We eventually got a whole lot of uptake in terms of using Graphite for stacking, and the rest is history.” The trial expanded, then eventually grew into a full-blown partnership. Shopify signed on as a customer and later, even, invested in Graphite through Shopify Ventures

By unifying their code into a single repository, Shopify has obtained a holistic view of projects, which enables efficient cross-team collaboration and greater cohesion in development efforts. This shift allows them to leverage shared libraries and integrated testing environments, leading, eventually, to more consistent and reliable builds. Moreover, the introduction of PR stacking within their monorepo has been a game changer. Stacked pull requests help engineers break sweeping changes into smaller, logical units.

“Let’s say you’re making a product change. Now you also have to update the API, the frontend, and the mobile app. That’s five different contexts,” he explains. “With Graphite, you stack those changes: three PRs for the backend, one for mobile, one for web. It’s the same work, but now it’s actually reviewable.” Since each PR is scoped to a specific intent, reviewers can evaluate a focused 50-line change instead of drowning in a 2,000-line monolith. With stacked PRs, teams working in monorepos can keep changes isolated, reviews fast, and development momentum intact—and maintain the quality that their customers have come to expect. 

Higher-quality, faster reviews

Beyond technical prowess, code review requires significant cognitive bandwidth. “The worst thing is opening a PR and seeing 10,000 lines. You don’t even know where to start,” Henrique says. “But if the PR says ‘refactor X,’ and it’s 50 lines, that’s doable. I can review those types of things in between meetings.”

In addition to keeping review cycles tight, stacking also improves review quality. Reviewers can stay engaged, while authors get faster, more actionable feedback. The result: teams ship more confidently, without sacrificing rigor. And when reviews do get blocked, that usually means something’s wrong. If a developer can’t approve a PR in a stack because the prior one isn’t ready, that’s not friction. That’s signal. 

Not every developer at Shopify was sold on stacking at first. “There were folks who loved it, folks who hated it, and a lot in between,” he recalls. Although junior engineers often faced challenges with stacking early on, anecdotally, they were also very keen on adopting the paradigm. Henrique often makes a personal appeal to new hires and junior engineers about why embracing tools like Graphite will pay off in the long run. “Your career is long. So the more tooling and the more tricks you pick up along the way… they will help you,” he tells them. That cultural support, combined with leadership buy-in from the top, helped stacking move from an experiment to an everyday practice. 

Now, 22% of all PRs merged at Shopify are part of a stack. 

Shopify’s journey with Graphite sets an example of how engineering leaders can modernize their dev workflows, especially in the face of rapid growth and scaling challenges. By adopting stacking, Shopify has empowered its developers to break down big changes, work more iteratively, and collaborate better in code reviews. What could have been a painful move to an enormous monorepo has instead become an opportunity to elevate their tooling and practices. The positive outcomes at Shopify, e.g., faster reviews, safer code changes, and happier developers, make a persuasive case for devs to start stacking in any growing codebase—and most importantly, the work scales.

Built for the world's fastest engineering teams, now available for everyone