I’ve been creating a zillion RewriteRules to perform 301 redirects, and the code has gotten ridiculous. I can’t even read it anymore.
I created a small tool that removes duplicate rules, reducing the number of matches that mod_rewrite needs to try. It also resolves chains of 301 redirects into a single redirect.
Check it out: Redirect Reducer.