Importing questions into Moodle from a Microsoft Word file using the Word table format (qformat_wordtable) fails more often than it succeeds on the first try, and the error messages rarely point at the real cause. This guide covers preparing the source document so the import works the first time, which question types actually import, and the prerequisites that are easy to miss.

Prerequisites people miss

Before anything else, requirements that cause confusing failures if absent:

  1. Install the companion plugin booktool_wordimport first. qformat_wordtable has a hard dependency on it (the Book module’s “Word import” tool), and Moodle will refuse to install the question format until it is present. All the actual Word-file parsing is delegated to it, so this is not optional. Install booktool_wordimport, then qformat_wordtable.
  2. PHP XSLT support must be installed (the php-xsl / libxslt extension). The plugin uses XSLT to transform the document, and without it the import simply does not work. HTMLTidy is also recommended. Confirm both before troubleshooting document formatting.
  3. The document’s language property must match your Moodle interface language. The importer reads a moodleLanguage property from the document; if it does not match the site/interface language, no questions import at all with little explanation. This is a genuinely common cause of “zero questions imported” and is easy to overlook.
  4. The advanced question types need their own qtype plugins. The OU drag-and-drop and All-or-Nothing Multiple Choice types import only if those question-type plugins are themselves installed.

How the format works

qformat_wordtable expects questions laid out in tables, each cell carrying a defined piece of the question (stem, answers, feedback, grades). The importer reads that structure literally, and it works in both directions: you can export existing questions to Word and re-import them, which is the basis of the template approach below.

Which question types import

This is the part to get right, because the support matrix is not intuitive:

Imported and exported (round-trip): Multiple choice, True/False, Short answer, Essay, Matching, Description, Cloze (embedded answers), the OU drag-and-drop and “select missing words” types (Drag and drop into text, onto image, markers), and All-or-Nothing Multiple Choice.

Cloze is in fact a flagship feature of this format: you author it without Moodle’s arcane Cloze syntax by using bold for drop-down items and italic for fill-in fields.

Exported only, NOT importable: Numerical and Calculated questions. The plugin can write them out to Word, but it cannot read them back in. If your set relies on Numerical or Calculated questions, author those natively in Moodle; they will not import from Word.

Authoring the document

Two supported approaches:

  1. Export a template from your Moodle. Export an existing question (or category) to Word using the Word table format, and author inside the resulting file. Its table structure is, by definition, what the importer expects to read back.
  2. Install the official Word template. For authoring new questions from scratch, the recommended aid is the custom Word template (moodleQuestion.dotx / moodleQuestionStartup.dotm) from Moodle2Word.net. It provides the correct structure and the macros that handle image conversion on export.

Either way, author inside a known-good structure rather than building tables by hand.

Document hygiene before importing

Word introduces formatting baggage that can disturb the table structure the importer relies on. Before importing, it is good practice to:

  1. Accept all tracked changes (Review > Accept > Accept All Changes) and turn track changes off, so leftover revision markup does not end up in the parsed content.
  2. Keep tables flat: avoid merged or split cells and nested tables, so each cell maps cleanly to the field the format expects.
  3. Clear stray formatting from content pasted out of other documents, web pages, or PDFs.
  4. Embed images rather than linking them; linked images will not import.
  5. Save as .docx. Legacy .doc (Word 2003) format is explicitly not supported; the importer requires Word 2010 .docx.

(The tracked-changes and merged-cell items above are sensible Word hygiene rather than formally documented failure modes; the firmly documented hard requirements are XSLT support, the language-property match, and .docx format.)

Importing

  1. Question bank > select the target category first.
  2. Import > choose Word table format (the option may read “Microsoft Word 2010 table format (wordtable)”) > upload the prepared file.
  3. Be aware of “Get category from file”: if enabled, category information in the document can override your selected category and create categories. Check this setting if questions land somewhere unexpected.
  4. Review the preview/result carefully before trusting it.

When it still fails

  • Zero questions imported, no clear error: check the moodleLanguage document-property-vs-interface-language match first, then confirm XSLT support is installed. These two account for most “nothing happened” cases.
  • Import error on a specific question: that question’s cell structure deviates from the template. Compare it against a known-good question in the same file and normalize the table.
  • A Numerical or Calculated question did not import: expected, those are export-only. Recreate them natively in Moodle.
  • Upgrade changed the behavior: the format is version-sensitive. After a Moodle upgrade, re-export a fresh template before importing again rather than reusing an old one.
  • Non-Latin text mangled: confirm .docx (not .doc) and Unicode throughout, and that the language property is set correctly.

The shortcut that prevents most pain

Confirm XSLT is installed and the document language matches your site, author inside a freshly exported template, keep tables flat, and save as .docx. Most failures never happen when the document started from the importer’s own structure and the two server-side prerequisites are in place. The same Word-generated markup problems that complicate question imports also break course content; if your authors paste from Word a lot, that habit is worth addressing at the source.

Solin specializes in Moodle question banks, assessment, and content migration. Need help? Contact us.

Need help with a Moodle or Totara project?

Contact us