Back to Community

Understanding and Resolving Performance Issues with Large Redirection Lists

51 threads Sep 9, 2025 PluginRedirection

Content

If you manage a WordPress site with a significant number of URL redirects, you might eventually encounter questions about performance and database load. This is a common concern for sites that have accumulated thousands of redirects over many years. This guide will explain how the Redirection plugin handles large datasets and provide practical steps to optimize its performance.

Does the Number of Redirects Affect Performance?

Based on community discussions and developer input, the Redirection plugin is designed to handle a large volume of redirects efficiently. The plugin's performance is generally constant, meaning the time it takes to process a redirect should not significantly increase as you add more entries. There is no hard-coded limit, and sites have been reported to function with tens of thousands, or even millions, of redirects. However, the overall health of your server and database is a crucial factor.

Why Large Log Tables Can Be a Problem

While the redirects themselves are optimized, the accompanying log and 404 tables can become very large over time. This is often the real source of performance issues. For example, one user reported their redirection_logs table was 103 MB and their redirection_404 table was 162 MB. These large tables can slow down database queries and increase server load.

Common Solutions and Optimization Tips

1. Manage Your Logging Settings

The most effective way to control database size is to limit how long data is stored. It is not recommended to keep 404 and log data "forever."

  • Navigate to Tools → Redirection → Options in your WordPress admin.
  • Under the 'Database' section, set a reasonable retention period for logs and 404s (e.g., 1 or 2 months). This will automatically prune old entries and prevent your database from growing indefinitely.

2. Consider Using NGINX Directives (For Advanced Users)

For sites with extremely high traffic or massive redirect lists (e.g., 6,000+), serving redirects at the server level can offer a performance benefit.

  • The Redirection plugin can generate NGINX configuration code for your redirects.
  • Go to Tools → Redirection → Groups.
  • Select the 'NGINX' redirect type for your group and copy the provided configuration code.
  • You must manually add this code to your server's NGINX configuration file. This task typically requires server administrator access.
  • Note: This method moves the processing load from WordPress/PHP to the web server itself, which is more efficient. However, any changes to these redirects would require updating the server configuration file.

3. Clean Up Unnecessary Data

  • Regularly review your 404 logs and use the 'Group by' dropdown to identify the most frequent errors. Consider creating redirects for legitimate broken links or ignoring spammy requests.
  • Delete any self-referencing redirects (where the source and target URL are the same), as these serve no purpose and can create loops.
  • Export your redirects to a CSV file and look for duplicates or outdated entries that can be removed.

4. For Developers: Cache Plugin Options

One advanced performance issue noted in the community is that the plugin's red_get_options function could call the database excessively on sites with a very high number of redirects. A code snippet was proposed to cache these options and reduce database queries. Implementing such a fix requires custom coding and is only recommended for developers comfortable with modifying plugin code.

Conclusion

Having a large number of redirects is unlikely to be the direct cause of a website crash. Performance problems are more commonly linked to oversized log tables. By proactively managing your data retention settings and considering server-level solutions for large-scale implementations, you can ensure the Redirection plugin continues to operate smoothly and efficiently, no matter how many redirects you have.

Related Support Threads Support