---
title: "Shopify"
description: "Global commerce platform powering millions of businesses with essential infrastructure and innovative engineering solutions."
---

# Shopify
> Global commerce platform powering millions of businesses with essential infrastructure and innovative engineering solutions.

## Articles

### [Deleting the Undeletable: Managing PII at Shopify - Shopify](https://yomu.fyi/post/deleting-the-undeletable-managing-pii-at-shopify-shopify.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Jun 10, 2021

Shopify describes how its Privacy and Data Science & Engineering teams redesigned analytical event handling to make personal-information deletion workable at Shopify’s scale. The effort addressed a lack of guaranteed event schemas by introducing a human-readable JSON schematization system covering field types, version evolution, ownership, data controllers and subjects, and privacy instructions; more than 4,500 active schemas now govern events. Before warehouse storage, identifying data is either obfuscated into generalized values, such as masked IP addresses with city or country information, or tokenized into consistent random values whose mappings reside in a secured vault and vary by controller and subject. Removing a vault mapping makes warehouse copies of the token non-detokenizable, allowing deletion without warehouse operations; the production platform processes about 20 billion events daily, while tens to hundreds of millions of mappings are deleted daily.


### [Updating Illustrations at Scale](https://yomu.fyi/post/updating-illustrations-at-scale.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Jun 3, 2021

Shopify’s Polaris team needed to update an illustration style across a product whose assets had become fragmented across more than 6,000 repositories. Illustrators and developers could not reliably identify an image’s repository, code references, reuse, or file type, while GitHub API limits and search behavior prevented dependable large-scale discovery. An initial Node.js monorepo cloned repositories, used globby to find PNG, SVG, and WebP files, searched source lines, and served JSON results through a Preact interface, but rebuilding 24 repositories took more than 35 minutes and produced inaccurate data. The team replaced it with @shopify/get-repo-images, a Go executable that parallelizes file operations, bundles crawling and site generation, and exposes a searchable Next.js interface through NPM. Search and build time fell to eight minutes, with repository cloning as the remaining bottleneck, and the tool was open-sourced.


### [Shipit! Presents: How We Write React Native Apps](https://yomu.fyi/post/shipit-presents-how-we-write-react-native-apps.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: May 27, 2021

A May 19, 2021 Shipit! event brought together Colin Gray, Haris Mahmood, Guil Varandas, and Michelle Fernandez, developers setting Shopify’s React Native standards, to discuss writing performant apps. The Q&A covers accessibility and design guidance through Restyle and Polaris documentation; their responsive layouts avoid fixed sizing where possible and use breakpoints for fonts and spacing. They describe React Native state as the usual source of truth while native modules manage internal state and send updates through EventEmitter, with SQLite in Point of Sale as an exception that still has one source of truth. Jest handles unit and integration tests, Buildkite manages CI builds, nightly builds are automatically distributed to testers, and failing feature-branch tests block merges to main.


### [How Shopify Built An In-Context Analytics Experience](https://yomu.fyi/post/how-shopify-built-an-in-context-analytics-experience.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: May 25, 2021

Shopify’s Analytics section gave merchants access to business data, but research and quantitative analysis found that they often moved between it and admin pages while making decisions. The team therefore designed an in-context experience for the Orders page, selecting metrics through workflow analysis, segmenting merchants by factors such as order volume and fulfillment process, and examining each metric’s usefulness, variability, and time horizon. Data scientists prototyped visualizations with real, segmented data and created a specification sheet so Web, Android, and iOS used consistent queries, data sources, fields, and aggregations; the project also tested batch models before streaming them. The launched experience surfaces order and fulfillment metrics for daily, seven-day, and thirty-day periods, with comparison indicators, and links to reports covering orders, returns, products, and fulfillment, shipping, and delivery times.


### [Other Driven Developments](https://yomu.fyi/post/other-driven-developments.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: May 21, 2021

The article argues that development models turn implicit lessons into shared, conscious practices as teams, codebases, and responsibilities grow. It presents Grep Driven Development, emphasizing expressive and consistent names so behavior remains searchable, refactorable, abstractable, and predictable, while warning that premature abstraction and locally “improved” naming can hinder later change. It also makes the case for Copy/Paste Driven Development as a deliberate, judgment-based tool, noting that duplication can be cheaper than the wrong abstraction and that abstractions with flags and conditionals may create their own costs. The article names Ego Driven Development and Stickler Driven Development among its four approaches, then concludes with Human Driven Development: choosing, bending, or breaking rules to make work easier for present and future teammates.


### [Three Ways We Share Context at Shopify Engineering](https://yomu.fyi/post/three-ways-we-share-context-at-shopify-engineering.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: May 13, 2021

Shopify Engineering treats context—the why, what, and how behind development philosophies, approaches, and choices—as essential to company, team, and individual growth. It describes the Development Handbook, which evolved from a 2015 Google Doc into a searchable internal website in 2018, with hundreds of developer-contributed topics maintained through GitHub pull requests, reviews, and Markdown. Dev Talks began as a weekly open stage and became an on-demand recording program after the 2020 shift to Digital by Design, with most presentations lasting 15 to 20 minutes. The Technical Leadership Team’s Shift podcast provides monthly, in-depth discussions of technical decisions, distributed in audio and video with transcripts. The programs continue to evolve while facing content-maintenance and participation challenges.


### [How I Define My Boundaries to Prevent Burnout](https://yomu.fyi/post/how-i-define-my-boundaries-to-prevent-burnout.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: May 6, 2021

The post describes how an intense, single-tasking software leader developed a sustainable way to divide work, family, and recovery time. After 100-hour startup weeks caused scattered thinking, dulled analytical ability, wrist problems, and an inability to type, the author found that a focused 60-hour, 9-to-9 schedule delivered 80 to 90% productivity compared with 100 hours, then shifted to a 9-to-6 model in 2009. The approach separates concentrated work from non-work, schedules blocks for writing, planning, reviewing, and thinking, and uses email and Slack response patterns to communicate boundaries and expectations. It lets lower-priority tasks fall away instead of extending work indefinitely into personal hours. The author says this structure supports recovery, family presence, and prioritization, while emphasizing that each person should experiment with a sustainable model rather than treat nine-to-six as universal.


### [A Five-Step Guide for Conducting Exploratory Data Analysis](https://yomu.fyi/post/a-five-step-guide-for-conducting-exploratory-data-analysis.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Apr 28, 2021

Exploratory data analysis (EDA) is presented as a practical way to describe a dataset, uncover patterns such as missing data, correlations, and outliers, and generate hypotheses that inform business questions and later data products. The guide recommends first clarifying the intended task with leadership and product, then checking dataset size, sample rows, and the unique row identifier; its synthetic merchant-behaviour example has 1,500 samples, 13 features, and one row per shop per day. It then advises examining missingness by feature, investigating why values are absent before deleting or imputing them, and classifying features as continuous, discrete, or categorical to guide analysis. Visualizing distributions and relationships helps reveal changes across samples and time, while box plots and percentile thresholds support systematic outlier review. The process is framed as a starting point whose findings can support regression, classification, or KPI-dashboard decisions.


### [Dynamic ProxySQL Query Rules](https://yomu.fyi/post/dynamic-proxysql-query-rules.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Apr 20, 2021

Shopify uses ProxySQL to manage application connections to MySQL databases, but applying query rules across thousands of ProxySQL instances is difficult, especially during incidents. ProxySQL rules can reroute, rewrite, or reject regex-matched queries, yet incorrect patterns may cause unintended rejection, rewriting, data corruption, or downtime. To make rule changes safer, Shopify added dry-run support to a ProxySQL fork, using the mysql\_query\_rules table’s active and log fields; dry-run rules log matched queries without executing their actions. A sidecar polls a global key-value store, synchronizes dynamic rules to each ProxySQL instance, caches rules, supports optional TTLs, and uses exponential backoff for broad logging patterns. The system favors consistency during synchronization failures, while static startup rules cover requirements for full availability.


### [Management of Native Code and React Native at Shopify](https://yomu.fyi/post/management-of-native-code-and-react-native-at-shopify.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Apr 16, 2021

Shopify’s Point of Sale team describes how its React Native strategy changed after limitations appeared in complex UI and background synchronization. The team kept complicated views in React Native, improving rendering with why-did-you-render, React DevTools Profiler, Application Performance Index measurements, memoization, lazy renders, and Reanimated 2 for drag-and-drop interactions. For background jobs, it built a native job manager with Kotlin Multiplatform Modules, sharing synchronization logic in common/ while isolating platform-specific file, database, networking, preferences, and threading code through libraries or wrappers and exposing it through React Native native modules. The resulting implementation shared approximately 95% of its code and reduced a medium-sized store’s initial sync from at least 30 seconds to 2–3 seconds, while the article notes KMM’s learning curve and recommends a separate library project for clearer boundaries and isolated sandbox testing.


### [How Shopify Dynamically Routes Storefront Traffic](https://yomu.fyi/post/how-shopify-dynamically-routes-storefront-traffic.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Apr 9, 2021

Shopify’s Storefront Renderer team rewrote the storefront implementation beginning in 2019 and needed a way to shift traffic between the legacy and new versions while migrating features. Using nginx with OpenResty, Lua modules, a control plane, and the spy chatbot, they moved routing rules from a Lua file into JSON payloads that could be created, updated, enabled, disabled, and deleted without a CI or deployment cycle. Rules selected shops and request subsets through filters, then controlled rendering and verification rates, including forward verification, reverse verification, and self-verification in the nearest region. During nginx request processing, matching occurs in the rewrite phase; verification is scheduled with timers in the log phase so duplicate requests run asynchronously after the client response path. The system supported gradual rollouts, parity checks, and resilience testing under Redis failures, while the team planned to simplify routing after the new storefront served almost all traffic.


### [Building Smarter Search Products: 3 Steps for Evaluating Search Algorithms](https://yomu.fyi/post/building-smarter-search-products-3-steps-for-evaluating-search-algorit.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Apr 1, 2021

Shopify’s Help Center serves more than 2 million users monthly, making search relevance important across setup, marketing, and troubleshooting queries. The post presents a three-step framework for evaluating new search algorithms against an existing system, combining data collection, offline metrics, and online A/B testing. It contrasts Vanilla Pagerank, which boosts articles by total views across searches, with Query-specific Pagerank, which uses click frequencies from historic searches containing the search term. Kafka event streams are modeled into search facts for near-real-time monitoring and experiment assignment, while Support-team annotations provide relevance labels for offline evaluation, with dataset staleness requiring recurring updates. In the reported A/B test, Query-specific Pagerank users clicked more, relied less on follow-up searches and later pages, and reached a lower average clicked rank; the algorithm replaced Vanilla Pagerank.


### [How to Build a Web App with and without Rails Libraries](https://yomu.fyi/post/how-to-build-a-web-app-with-and-without-rails-libraries.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Mar 26, 2021

This tutorial builds Mirth, a Ruby web application that lets users view displayed data and enter new data that persists, using a birthday tracker as its example. It first constructs the application with core Ruby libraries, explaining TCP sockets, HTTP requests and responses, persistent storage, and the need for a web server interface such as Rack. It then replaces that lower-level code with Rails libraries, including Action Controller, Action Dispatch, Active Record, and Action View, while using ERB templates and a configured view path. The tutorial shows how routing, database access, request handling, and HTML generation fit together, with the application available at localhost:1337/birthdays after the Rails-library version is run. Its conclusion is that building from scratch clarifies the implementation details Rails hides, while Rails remains the practical choice for web development.


### [Remove Circular Dependencies by Using Dependency Injection and the Repository Pattern in Ruby](https://yomu.fyi/post/remove-circular-dependencies-by-using-dependency-injection-and-the-rep.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Mar 19, 2021

An internal Ruby pricing gem used by Shopify Core and Storefront Renderer needed consumer-owned data while retaining shared pricing knowledge, creating a circular dependency. The proposed design puts calculation logic and shared domain types in a stateless gem, while each consumer implements a repository contract for retrieving and returning the required data. Constructor injection passes a PricingRepositoryInterface implementation into PricingEngine::Engine, and Sorbet interfaces and function signatures enforce implemented methods and expected return types. Testing separates gem-isolated tests using repository mocks, consumer unit tests for repository behavior, and integration tests confirming the gem works within each consumer. The result, according to the post, is removal of the circular dependency and a typed contract that makes consumers responsible for data access.


### [Capturing Every Change From Shopify’s Sharded Monolith](https://yomu.fyi/post/capturing-every-change-from-shopify-s-sharded-monolith.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Mar 12, 2021

Shopify’s separate internal warehouse and Merchant Analytics Platform created duplicated work, differing extraction results, and incompatible tooling while demand grew for fresher, low-latency merchant data. Longboat, its query-based CDC service, polls sharded-monolith replicas in batch jobs using updated\_at, but queries can run only hourly and cannot detect hard deletes or updates that bypass that field. Shopify therefore adopted Kafka and Debezium CDC to capture database changes, standardize extraction, and make the event stream usable by both streaming and batch consumers. CDC-backed Beam modeling reduced average freshness for one migration from one day to one hour, while Kafka became a shared source for operational and analytical data. Shopify still identifies incremental snapshotting and streaming-state problems, including reconciling MySQL table chunks with ongoing binlog events without expensive locks, as ongoing work.


### [Updates on Shopify's Bug Bounty Program 2021 - Shopify](https://yomu.fyi/post/updates-on-shopify-s-bug-bounty-program-2021-shopify.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Mar 11, 2021

Shopify’s 2021 bug bounty update reviews a busier 2020 program and outlines planned improvements for hackers and internal responders. Its first virtual live hacking event brought together 38 hackers from seven countries, generated 83 valid reports, and paid more than $220,000 in bounties plus $54,000 in bonuses. Shopify also raised its maximum bounty to $50,000, surpassed $2 million in total awards, replaced its bounty table with CVSS-based scoring and a public calculator, and published a GraphQL hacking guide. To handle volume, the Application Security team created a dedicated HackerOne team, built a dashboard for follow-up questions, and planned more resources and a revised private Experiments program. In 2020, Shopify triaged 215 reports, paid over $460,000, and reported an average first-response time of 25 hours, while average triage and bounty times increased.


### [4 Tips for Shipping Data Products Fast](https://yomu.fyi/post/4-tips-for-shipping-data-products-fast.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Mar 2, 2021

Shipping data products under tight deadlines requires teams to stay focused while avoiding overengineering and building something users will not use. Shopify’s Data Science team recommends four practices: run a timeboxed design sprint with a small team and a designated Champion, prototype quickly—often with spreadsheets—and gather feedback throughout development. For first iterations, the post advises using simple approaches instead of machine learning when complexity would delay integration, polish, and user conversations; a sales forecasting prototype used linear regression with two input variables before a more complex model was built. User research should use specific questions and a diverse set of users, as feedback changed a confusing 0–100 scoring display to easier-to-interpret letter grades. Together, these practices provide a clearer path to launching useful products quickly.


### [Keeping Developers Happy with a Fast CI](https://yomu.fyi/post/keeping-developers-happy-with-a-fast-ci.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Feb 24, 2021

Shopify’s Test Infrastructure team tackled a 45-minute 95th-percentile CI time for its Core monolith, which had more than 170,000 tests and ran on every git push. They instrumented Buildkite commands and prioritized agent preparation, dependency building, and test execution using command frequency and duration. Disk I/O from writing large caches slowed Docker startup, so the team increased disk capacity and write speed, mounted most caches read-only, skipped unchanged database and asset work through hashes, parallelized setup, and expanded changed-file test mappings. These changes reduced container-start p95 from 90 to 25 seconds, raised builds avoiding the full suite from 45% to over 60%, improved test stability from 88% to 97%, and lowered overall CI p95 to 18 minutes.


### [Read Consistency with Database Replicas](https://yomu.fyi/post/read-consistency-with-database-replicas.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Feb 22, 2021

Database replicas can improve read-heavy application performance and reduce pressure on primary servers, but differing replication lag can make multi-query reads produce incoherent datasets. Shopify’s Database Connection Management team compared tight consistency and GTID-based causal consistency before choosing opt-in monotonic read consistency, in which related reads are routed to one replica and therefore follow a consistent timeline rather than necessarily seeing the latest data. Their ProxySQL fork accepts a UUID in the consistent\_read\_id query comment, hashes it into a pseudorandom index over a weighted hostgroup server list, and disables later rebalancing that could override the selection. The implementation indexes configured servers before handling outages, though a selected server failure can still break consistency. The approach offers low overhead but tolerates occasional inconsistencies.


### [Bound to Round: 8 Tips for Dealing with Hanging Pennies](https://yomu.fyi/post/bound-to-round-8-tips-for-dealing-with-hanging-pennies.md)
- Company: [Shopify](https://yomu.fyi/company/shopify.md)
- Author: 2023-10-18
- Published: Feb 16, 2021

Financial software must round values when money cannot be transacted beyond two decimal places, creating precision loss and “hanging pennies.” The post demonstrates that rounding two percentage-based charges separately on $10.10 produces $0.53, while summing the unrounded amounts and rounding once produces $0.54; currency conversions can amplify the effect. Its eight recommendations include notifying stakeholders, using banker’s rounding, retaining maximum available precision in data types, applying one consistent method, marking rounding explicitly, consulting government standards, rounding only when required, and documenting rules for users. It identifies taxes, discounts, interest, distributed payments, shared liabilities, and rates as recurring sources of rational values in financial calculations. The conclusion is that rounding cannot be avoided in financial software, but teams can control where it occurs and how its consequences are handled.


[Newer posts](https://yomu.fyi/company/shopify/page/11.md) · [Older posts](https://yomu.fyi/company/shopify/page/13.md)
