Migrate pages from Wiki extension to a team project wiki

VSTS | TFS 2018

With the release of the built-in wiki, any wiki pages that you created using the Wiki Marketplace extension have been saved to a Git repo in your team project.


Feature availability: Use this topic to migrate pages made using the Wiki Marketplace extension to the VSTS Wiki. The Wiki* hub is in Preview and available for VSTS and TFS 2018 and later versions. You enable this feature for a team project from the Preview features option from your profile menu. To learn more, see Create a wiki for your team project.

You can migrate the markdown pages and other artifacts that were added to that repo to your team project wiki with these steps:

  1. Clone vsts-wikiTools repository and compile the MigrateToVSTSWiki tool
  2. Create and then clone your VSTS wiki
  3. Move and commit all markdown pages to your VSTS wiki
  4. Run the wiki migration tool, MigrateToVSTSWiki.exe
  5. Once you are done, push the changes to the default master branch, wikiMaster, of the VSTS wiki repository.

To perform these changes, you must be a member of the Contributors group of your team project.

Detailed steps

Here are the detailed steps for Wiki migration:

  1. Clone vsts-wikiTools repository and compile the MigrateToVSTSWiki tool

  2. Compile the project under the path Tools/MigrateToVSTSWiki to generate the migration tool EXE.

  3. From a web browser, open your VSTS team project and create your first wiki page.

  4. Get the URL to clone your wiki. See Clone your wiki and edit wiki pages offline.

    Let the clone location be identified as "LocationA" for the purposes of these procedures.

  5. Clone your Wiki repo using your IDE or git clone command.

    Manage wikis menu option

  6. Clone the Wiki extension repo. The Wiki will be mapped to a folder given to you during the wiki creation. You can check that by going to "manage wiki" option in the existing wiki as shown below.

    You'll find your existing wiki pages are saved under the folder labeles "Root".

    For example, say you have cloned the above mentioned "sampleWiki" in the location "C:\wiki\sampleWiki". The wiki pages are saved in the path "C:\wiki\sampleWiki\ _extensionWiki"

    Let this location be identified as "LocationB" for the purposes of these procedures.

  7. Create an empty folder in any path of your choosing in your local machine and let that be "LocationC" for the purposes of these procedures.

    In summary:

    • Location A = VSTS Wiki repo
    • Location B = Wiki extension repo
    • Location C = Empty folder where we will run our migration tool
  8. Open a command prompt as an administrator and run MigrateToVSTSWiki.exe. This tool will copy the files from your existing wiki to the destination directory you provide. During copying, the tool converts the pages to be compliant with the VSTS wiki.

    MigrateToVSTSWiki.exe /source:LocationB /destination:LocationC

    For example:

    • "E:\wiki\sampleWiki_extensionWiki" is the folder in which the existing wiki files are present
    • "E:\Temp\Wiki\New" is the empty folder into which the migrated files are to be copied.
  9. Next, remove all files from "LocationA" (if any) apart from the git related files such as .gitignore etc.

  10. Copy all files from "LocationC" and paste them into "LocationA".

  11. Run git add . to stage all the newly added files in "LocationA" for the commit.

  12. Run git commit -m to commit the files that you have staged locally.

  13. Run git push origin wikiMaster -f . to push the changes to the default branch of the VSTS Wiki.


Once you have migrated your Wiki extension files to the VSTS Wiki, you are ready to uninstall the Wiki extension.


This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.