Disable Random Content

Disable Random Content turns off the random redirects that came with WordPress 7.2: /random/ opens a random published post, and archives have random URLs of their own, such as /random/category/blog/. The plugin turns them off as soon as it is activated and keeps random links only for the archives you choose. KAGG Design develops the plugin.

Features

  • Turns off /random/, the random archive URLs and the random query parameter right after activation, with no settings
  • Random links for selected categories, tags, terms of other public taxonomies and post type archives, under Settings → Disable Random Content
  • Works with WPML and Polylang: a random link for an archive in one language, while its translations stay off
  • A random link for a selected WooCommerce product category
  • WordPress Multisite: activation on one site or across the network, and each site keeps its own archive selection
  • Activation on WordPress 7.1 ahead of the upgrade: the plugin takes over random redirects once the site runs WordPress 7.2
  • Permalink rules update automatically. Published content stays at its usual URLs, and random ordering in themes and other plugins is not affected

Links

For developers

The plugin works through the WordPress wp_enable_random_content_redirect filter and follows a custom random base set in Settings → Permalinks, such as /shuffle/. It installs and activates with WP-CLI, on one site or across a Multisite network. It needs no settings and no manual permalink changes.

Terminal · WP-CLI
# One site
wp plugin install disable-random-content --activate

# Multisite network
wp plugin install disable-random-content --activate-network