---
title: "Using DNS Traffic Management to Add Resiliency to Shopify’s Services"
description: "Shopify consolidated several team-specific DNS traffic-management approaches that relied on manual changes, pull requests, or provider APIs and had uneven failover, redundancy, and active/active capabilities. The replacement was a fully automated, self-served system for more than 40 domains owned by more than 12 teams and handling more than 100M requests per day. It stores domain configuration in Git, deploys it to two DNS providers, and exposes spy commands for fast updates and failovers. Its traffic-management design uses regionalized matching, endpoint-status filtering, weighted sharing, and fallback layers, while globally matching endpoints ensure an existing domain receives an answer. A later provider migration demonstrated the value of centralized ownership: the team updated Terraform and tooling, moved nameservers incrementally, and kept the change transparent to application owners despite concurrent incidents."
---

# Using DNS Traffic Management to Add Resiliency to Shopify’s Services

[Shopify](https://yomu.fyi/company/shopify) · 2023-10-18 · Aug 5, 2020

**Type:** Problem & solution

## Summary

Shopify consolidated several team-specific DNS traffic-management approaches that relied on manual changes, pull requests, or provider APIs and had uneven failover, redundancy, and active/active capabilities. The replacement was a fully automated, self-served system for more than 40 domains owned by more than 12 teams and handling more than 100M requests per day. It stores domain configuration in Git, deploys it to two DNS providers, and exposes spy commands for fast updates and failovers. Its traffic-management design uses regionalized matching, endpoint-status filtering, weighted sharing, and fallback layers, while globally matching endpoints ensure an existing domain receives an answer. A later provider migration demonstrated the value of centralized ownership: the team updated Terraform and tooling, moved nameservers incrementally, and kept the change transparent to application owners despite concurrent incidents.

## Context

Multiple Shopify teams had independently built DNS traffic-management systems, creating maintainability problems, coordination overhead, inconsistent capabilities, delayed failovers, limited active/active support, and in some cases dependence on a single DNS provider. The organization wanted regionalized traffic, fine-grained sharing, failover capabilities, and easy self-service for domain owners.

## Approach / What changed

Shopify created a unified, automated service with domain configuration stored in Git and deployed to two DNS providers. Teams use spy commands to update both providers and perform failovers, while layered traffic management handles geographical fencing, endpoint status, weighted traffic sharing, and fallback behavior. Central ownership also supports provider migrations and shared tooling.

## Takeaways

- The standardized system serves more than 40 domains across more than 12 teams and handles more than 100M requests per 24 hours.
- Using two DNS providers improves redundancy and avoids dependence on a single provider after a previous DNS outage during a DDoS attack.
- Centralized ownership allowed a provider migration to be rolled out incrementally through Terraform, synchronized tooling, and controlled nameserver changes.

**Tags:** [DNS](https://yomu.fyi/topic/dns), [Reliability](https://yomu.fyi/topic/reliability), [Terraform](https://yomu.fyi/topic/terraform)

- Source: [Shopify](https://shopify.engineering/using-dns-traffic-management-add-resiliency-shopify-services)
- Source URL: https://shopify.engineering/using-dns-traffic-management-add-resiliency-shopify-services
- Ingested by Yomu: 2026-08-31T01:12:02.247Z

[Read original post](https://shopify.engineering/using-dns-traffic-management-add-resiliency-shopify-services)
