SM

    slug migration 301 redirects

    1

    Generate disk-verified 301 redirect maps for Nginx to fix 404 errors after URL structure changes.

    Free

    Security scanned

    Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+22 more

    About this skill

    Changing a URL structure or fixing a slug-generation rule often leads to a massive spike in 404 errors. These broken links destroy SEO authority and waste crawl budget as Google spends months retrying dead pages. This skill automates the generation of verified 301 redirect tables specifically for Nginx environments.

    What it does

    • Slug reconstruction identifies the transformation logic required to map old URLs to their new equivalents.
    • Disk-level verification ensures a redirect is only created if the old path is missing and the target path exists.
    • Nginx map generation produces structured map files that handle thousands of redirects without bloating server configurations.
    • Config auditing checks for common Nginx pitfalls like map_hash_bucket_size limits and symlink mismatches.
    • Safety validation provides a workflow for testing configuration syntax and verifying redirect headers before production deployment.

    How it works

    1. Configure the generator by defining the site root and the specific slug transformation rule in the Python script.
    2. Execute the verification script to scan the filesystem and identify valid redirect pairs.
    3. Deploy the Nginx map to the server, ensuring the map_hash directives are present to handle large datasets.
    4. Test and reload using nginx -t to confirm syntax before applying the changes to live traffic.

    Frameworks & tools

    This skill utilizes Python for filesystem scanning and URL mapping. It is designed for Nginx web servers using map blocks for efficient redirect handling.

    Why this beats prompting it yourself

    Generic AI prompts often suggest regex rules that cause collateral damage to valid URLs. This skill enforces a "verify on disk" requirement, ensuring every single redirect leads to a live page and never creates a redirect loop or a broken target.

    Use cases

    • Migrating a blog structure from /post/slug to /articles/slug.
    • Removing redundant category suffixes from thousands of indexed product URLs.
    • Cleaning up Search Console 404 errors after a site-wide redesign.
    • Preserving SEO link equity when changing URL naming conventions in a CMS.

    Known limitations

    This skill requires the site to be served from a static filesystem for verification. It is not suitable for dynamically generated URLs that do not exist as files on disk.

    How to use

    Skills on Agensi run inside your AI agent. Copy the prompt, paste it into your agent, and it connects to Agensi and installs this skill for you. If a payment is needed, your agent shows it to you first.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill passes our trust checks below.

    Security scanned

    Passed our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Free forever

    No account required to browse

    Trust & safety

    Security scanned

    Verified clean 1 day ago

    • Free to download with an account

    Listed1 day ago

    What's inside

    Frequently Asked Questions

    Free