Tragic Tragic Software & Cloud Solutions | San Diego • Seattle Blog

The Walking Dead .htaccess Challenge

Reading Time:< 3 Min
Published:June 25, 2020
Last Modified:July 20, 2022

During its peak, The Walking Dead (TWD) utilized its own website filled with thousands of pages of content on the series.

At some point, the TWD intellectual property was absorbed into the main Skybound website. For SEO purposes, all TWD pages were mapped to the Skybound website using 301 Redirects (to maintain the previous domain's authority).

The Challenges with .htaccess

To correctly move TWD website, the pages had to be mapped to Skybound via a .htaccess file - a configuration file for sites running Apache Web Server. The .htaccess file tells the web server how to handle redirects, authorization, errors, and more.

When it was all said and done, there were over 6,000 redirects in the .htaccess file to send traffic from to

Normally a .htaccess file is a good approach for handling url redirects, but the solution does not scale well.

The previous development team used a WordPress plugin to export the desired redirects from TWD, though the Skybound team had to manually edit many of the redirects to be correct. When it was all said and done, there were over 6,000 redirects in the .htaccess file to send traffic from to

Recently, the Tragic team was in the process of migrating all Skybound properties from Rackspace to Amazon Web Services (AWS). During this process, one of the old web servers (that was already migrated) was shut down - which, in turn, broke all 6,000 redirects.

Even worse, we learned about this .htaccess file when the client informed us that one of their biggest domains had stopped redirecting traffic.

After some investigation, we discovered that The Walking Dead domain was still pointing to that specific Rackspace server in order to redirect traffic to the Skybound domain. It seems that this server's sole purpose was to redirect traffic and maintain domain authority.

One problem with an .htaccess file is that people forget about them. Or where they reside. If you are not running Apache or have a complicated site infrastructure a .htaccess file may not be ideal or work at all. In addition, these files are incredibly difficult to manage at this scale. Nobody wants to go line-by-line trying to resolve a typo or fix a bad redirect. Finally, this solution is not performant and requires all traffic from the originating domain to process every line of the redirect file before redirecting.

Brainstorming a New Solution

When we saw this mess, we rolled our sleeves up and designed a new solution.

Our solution utilizes a JSON file and a Lambda function with simple regex rules. Regex stands for regular expression which is a series of characters that define a search pattern. Regex is a core computer science technique that is used heavily in web development and matching algorithms.This solution is completely serverless, so it can scale up and down to meet demand without any provisioning.

Because of our use of serverless computing, there is no cost to The Walking Dead unless traffic actually needs to be redirected. Moreover, it is more manageable to add, remove, and update 301 Redirects in this method. Before, the .htaccess file was bursting at its seams.

We were able to reduce engineering headache, save cost, and improve the user experience all at the same time.

The regex rules being used are faster and more efficient compared to going through 6,000 redirects one at a time. The end result is faster load times for redirected visitors. Lastly, Lambda shows what requests are being made so that Skybound has better insight into what TWD traffic is still active. These granular insights were not available before.

You can find the repository with our Lambda solution here.


Solutions are never one-size-fits-all. As you start to scale, you want to leverage a variety of tools, frameworks, and architectures depending on what you are building (or maintaining).

There are many ways to implement 301 Redirects depending on your architecture - .htaccess rules are standard, but not designed for a website of this size or with this volume of traffic.

At Tragic, we have worked with a number of companies, from fast-growing startups to industry-leading enterprises. We know what tools to use and what tradeoffs come with each option. In this case, we were able to reduce engineering headache, save cost, and improve the user experience all at the same time.

Are you looking to learn more about how to improve your technical infrastructure? Contact Tragic today for a free technology consultation.


#Code View All