MediaWiki to Confluence Migration

Vidhya Hari picture Vidhya Hari · Apr 15, 2016 · Viewed 7.3k times · Source

We are planning to migrate our existing MediaWiki site to Confluence. But when I searched about it, I came to know about the Universal Wiki Converter(UWC) tool, which is no longer supported or available. So, I am worried as to where to start and how to proceed. We have planned to export all the MediaWiki pages to XML and then import them to confluence.

So, my question here is whether this is a right approach and how can XML can be imported easily to Confluence?

Answer

Paul Sweatte picture Paul Sweatte · Nov 1, 2016

Use Markdown as the universal format for import/export. Markdown can be imported or exported to MediaWiki:

Markdown-Wiki

Simple tool for converting wiki 2 markdown and other way round.

Install

Tool expects that you have npm installed on your system.

npm install markdown-wiki

Usage

cat foo.wiki | markdown2wiki > foo.md

and Confluence can render Markdown:

Markdown for Confluence provides macros that render Markdown content on Confluence pages. The content can be entered directly in the body of a the markdown macro or be from an attachment or URL.

or Markdown can be converted to HTML and rendered by Confluence:

npm install markdown-html

markdown-html in.md -o out.html

XML export would require XSLT or some equivalent to convert from the MediaWiki XML Schema to the Confluence XML Schema, if the above is not a viable option.

References