• Resolved maryando

    (@maryando)


    Hi guys,

    I have manually migrated my site from staging environment to the live domain.
    The site is working correctly but I found we dropped in Google ranking and found so many old URL’s pointing to the staging subdomain.

    The problem I created I think, was not disabling Yoast plugin on time on staging subdomain. Then moved entire site to the live domain where plenty links already contained a subdomain URL’s.
    So, now in database in Yoast tables I have plenty bad URL’s destroying day by day my SEO ranking.
    Is there any way to fix this?

    Many Thanks.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support Michael Ti?a

    (@mikes41720)

    Hi @maryando

    This occurs when the indexables process runs on the staging environment and those staging URLs are retained when you’ve migrated from staging to live. Typically, the SEO data optimization process should be disabled on non-production environments.

    Can you please try resetting our indexables in the database tables by following the steps below?
    1. Install & activate the?Yoast Test Helper plugin
    2. Go to Tools > Yoast Test
    3. Locate the Yoast SEO section and click on the ‘Reset indexables tables & migrations’, ‘Reset Prominent words calculation’, and ‘Reset Internal link counter’ buttons. After each click, the page will reload to confirm that each reset was successful. Note: this won’t actually erase your SEO data, which is also stored in WordPress’ default tables. It’ll just reset our index (custom tables) for that data.
    4. Go to SEO > Tools, and under SEO data, click the “Start SEO data optimization” button to allow Yoast to rescan your?content.

    For your site’s health and safety, we recommend creating regular backups of your site and database. This is especially important before installing, updating or removing plugins. Learn more about the benefits of regular backups.

    Could you then check if the data then reflects the production or live site?

    I also have this every time I move a staging site live.

    You can force a reindex with WP CLI, which seems to fix it:

    wp yoast index –reindex

    It would be better if performing a wp search-replace also adjusted the Yoast data though.

    Thread Starter maryando

    (@maryando)

    Thanks guys!

    I have already fixed this yesterday, well today at night ??

    Database URL’s changed as ‘Yoast Test Helper’ as Michael mentioned above as found this on other forum last night.
    The rest of 13 entries in database changed manually but all database problems was mainly from Yoast.
    Then all site links changed by VSCode.
    All works as it should now.

    The funny thing is that I still don’t know if this is a normal situation.
    I understand the mess with the Yoast plugin, that before moving the website to the staging environment the plugin need to be disabled. Then enabled only when the site is back to the live domain, but I’m still don’t know if this is correct way of doing this.

    Then why all other links changed.

    So what I did exactly?
    Because I was revamping the website totally I decided to move it to the staging domain and work there then when the web is finished move it back to the original domain.

    Is moving WordPress not that simple as:
    – zip the web folder and move it to the another domain
    – moving database,
    – changed the URL’s in database in _options table,
    – changed the database details in wp-config file,
    Is something else must be done in order to do it correctly?
    Or maybe all was done correctly and WPRocket, Yoast created this mess?

    I found so many URL’s from staging domain in so many files that this is just crazy for me.

    Andy, thanks, yes, I need to put my hands on WP CLI for sure.

    Plugin Support Michael Ti?a

    (@mikes41720)

    Hi,

    We’re glad to hear that you were able to resolve the issue.

    We’re not exactly sure what occurred when you moved from the staging site to production, but we do have a guide here on how to push updates from the staging site to live site – https://yoast.com/help/how-to-push-updates-from-a-staging-site-to-a-live-site/

    As per the changelog, as of Yoast SEO v15.5, it should prevent the indexables from running in the background.

    Prevents several processes from happening on non-production environments:
    -Indexing indexables.
    -Pinging search engines about XML sitemaps.
    -Sending tracking information.
    -Checking the indexability of the site with Ryte

    Should any staging URLs appear in the live site, we would recommend resetting it with the Yoast Test Helper tool, and then rerunning the SEO data optimization process, or by running the indexables process through WP-CLI.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Migrated Site – Yoast URL’s problem’ is closed to new replies.