Index
Symptoms
You run a ShareGate Migrate PowerShell script and get the following error:
The connection failed because a site was not found at [provided URL]. If [Fallback URL] was the intended URL, you can correct the URL or use the -AllowConnectionFallback switch in your script. Note that the connection fallback could overwrite a root site collection.
Details
If the URL you provided for your connection in your script is to a site that does not exist, contains information for a page or library, or is not responsive, the app has the ability to fallback to a site it detects within the URL you provided.
The app does not fallback automatically to your site to avoid unwanted to migrations to the wrong site or a root site collection because these actions are difficult to revert.
Solution
The error message in PowerShell provides you with an indication of what is wrong with the URL. You can correct the URL in your script, or in your CSV if you are using a foreach loop statement.
If you are certain the fallback will not affect unwanted sites or root site collections, you can add -AllowConnectionFallback to the connection line in your script to get the app to fallback to the site automatically.