# Aiken format converter for Moodle: GIFT, XML | Evalmee

> Paste questions from Word, Excel or plain text and download a valid Aiken, GIFT or Moodle XML file, ready to import into Moodle. Validates an existing file and shows the line that breaks. Free, in your browser.

Source: https://evalmee.com/en/tools/moodle-question-converter/
FR: https://evalmee.com/fr/outils/convertisseur-moodle-aiken-gift/
ES: https://evalmee.com/es/herramientas/convertidor-moodle-aiken-gift/
ES-ES: https://evalmee.com/es-es/herramientas/convertidor-moodle-aiken-gift/
IT: https://evalmee.com/it/strumenti/convertitore-moodle-aiken-gift/

---

## Moodle converter: Aiken, GIFT, XML

From Word, Excel or plain text to a file Moodle imports without error — and validation of an existing file.

## Moodle question converter: Aiken, GIFT and Moodle XML

From Word, Excel or plain text to a file Moodle imports without error — and the exact line that breaks, when an import fails.

Everything is converted in your browser; no question and no file is ever sent to a server.

Or import these questions straight into Evalmee — same file, no Moodle step.

## How to convert questions for Moodle

### Give it your questions as they are

Paste the text of your paper, drop the Word document you wrote it in, or drop the Excel workbook (.xlsx) or the CSV your spreadsheet exported. The converter recognises questions that are numbered or separated by a blank line, choices marked A) A. a) - or •, and the correct answer marked with a star, with an ANSWER: line, with bold text in a Word document, or in the last column of a table.

### Check what it understood

Every question it found appears on a card: the stem can be edited, the correct answer is a click away, and a counter tells you how many questions are ready and how many still need fixing. Errors are reported line by line, with the reason — which is the part Moodle will never tell you.

### Download the format your Moodle expects

Choose Aiken for a plain multiple-choice test, GIFT for several correct answers or per-choice feedback, Moodle XML for everything else. The file downloads or copies, and imports into your course's question bank.

## What is the Aiken format?

Aiken is the simplest import format [Moodle](https://evalmee.com/en/assessment-glossary/#moodle) accepts: a plain text file, one question per block, with no tags and no special punctuation. It holds five rules, which is both its strength — anyone can write it in Notepad — and its limit: it can only express a single-answer multiple-choice question.

An Aiken file is written in UTF-8 and imported into the course question bank. This is what the file Moodle's own documentation gives as an example looks like:

```
What is the capital of France?
A. Lyon
B. Marseille
C. Paris
D. Bordeaux
ANSWER: C

Which river runs through Paris?
A) The Seine
B) The Rhone
C) The Loire
ANSWER: A
```

### The five rules of the Aiken format

The stem takes the first line of the block, with no number and no prefix.

The choices follow, one per line, prefixed with a capital letter and a full stop or a bracket: A. or A), from A to Z, in order and with no gap.

The last line of the block gives the answer as ANSWER: followed by the letter — in capitals, which is the single most common cause of a failed import.

Only one answer can be correct: Aiken cannot express multiple answers, a short answer or a number.

A blank line separates two questions.

## What is the GIFT format?

GIFT is Moodle's native text format, and the one to learn once Aiken is no longer enough. It expresses a question title, several correct answers with their weights, feedback on each choice, true/false, short answers and numerical answers with a tolerance — everything Aiken leaves out.

It charges for that in six characters that mean something: the tilde, the equals sign, the hash, the two braces and the colon. An equals sign left unescaped in a stem raises no error at all: Moodle silently reads the rest of the sentence as a correct answer. This converter escapes them for you, and tells you it did.

```
::Capital:: What is the capital of France? {
    ~Lyon
    ~Marseille
    =Paris #Since 987.
}

::Primes:: Which of these numbers are prime? {
    ~%50%2
    ~%50%3
    ~%-100%4
}

::Orbit:: The Earth orbits the Sun. {T}

::Author:: Who wrote Candide? {=Voltaire =Francois-Marie Arouet}

::Product:: What is 3 x 7? {#21:0.5}
```

### The characters to escape in GIFT

Six characters must be preceded by a backslash wherever they appear in a stem, in a choice or in a feedback line: ~ = # { } and :

A stem that reads "x = 3" is therefore written "x \= 3". It is mechanical, nobody does it by hand without slipping, and it is exactly what the converter takes off your plate.

## Moodle XML format

Moodle XML is the format Moodle exports itself, and the only one of the three that carries everything at once: images, question bank categories, feedback on each choice, partial credit and all ten question types. It is also the only one nobody writes by hand — which is precisely where a converter earns its keep.

Prefer it as soon as your paper goes beyond the single-answer multiple choice: several correct answers with weights spread between them, feedback attached to each distractor, an image in the stem, or a bank to file by category. This converter writes the four types Moodle imports most often — multichoice, truefalse, shortanswer and numerical — with the single and shuffleanswers elements and the fractions Moodle expects.

A Moodle XML file dropped here is also read back: its questions are shown, the types it carries that this converter does not are listed by number, and it can leave as Aiken or as GIFT. The same job on a [QTI](https://evalmee.com/en/assessment-glossary/#qti-question-and-test-interoperability) package bound for Canvas or Blackboard belongs to another tool.

## Aiken vs GIFT vs Moodle XML

All three formats import at the same place in Moodle. They simply do not say the same thing, and a perfectly valid Aiken file stays a single-answer multiple-choice question whatever you do to it.

| What you want | Aiken | GIFT | Moodle XML |
| --- | --- | --- | --- |
| Single choice | Yes | Yes | Yes |
| Several correct answers | No | Yes | Yes |
| True/false, short answer, numerical | No | Yes | Yes |
| Feedback per choice | No | Yes | Yes |
| Partial credit | No | Yes | Yes |
| Images in the stem | No | No | Yes |
| Question bank categories | No | No | Yes |
| Writable by hand without the docs | Yes | Almost | No |

## Why does my Moodle import fail?

Moodle refuses a file while almost never saying why, and often without saying where. Six causes cover very nearly every failure; the validator on this page detects all six and gives you the line number.

| What Moodle shows | What is actually happening | The fix |
| --- | --- | --- |
| "ANSWER line not found" | The block has no answer line, or it is not in capitals | Write ANSWER: followed by the letter, in capitals, on the last line of the block |
| An import that only creates some of the questions | The blank line between two questions is missing, so Moodle merged them | Separate every question with a blank line |
| "Error importing question" | Two answers are marked correct in an Aiken file | Move to GIFT or Moodle XML, which can express multiple answers |
| Choices missing from the imported question | The choice letters do not follow on: A, B, D | Renumber the choices in order, with no gap |
| A question cut off in the middle of a sentence | An unescaped GIFT character — ~ = # { } : — was read as syntax | Escape the six characters, or go back to Moodle XML |
| Accented letters replaced by question marks | The file is not in UTF-8 | Save the file as UTF-8 without a BOM; the downloads on this page already are |

## How to import the file into Moodle

The path has not changed since Moodle 3.x. In your course, open More, then Question bank, then Import. Choose the file format — Aiken format, GIFT format or Moodle XML format — drop the file, pick the destination category, then run the import.

Moodle then lists the questions it understood before saving them: that is the moment to check the count. The official Aiken page is published at docs.moodle.org/en/Aiken_format, the GIFT one at docs.moodle.org/en/GIFT_format.

If you import the same banks regularly, keep the source file: that is what gets reconverted, not the export.

## Which format for which question

The rule fits in four lines. Read it top to bottom: the first format that accepts what you need to express is the right one, because it is also the one that will be easiest to read again in six months.

```
one correct answer                  → Aiken, GIFT or Moodle XML
several correct answers             → GIFT or Moodle XML
true/false, short answer, numerical  → GIFT or Moodle XML
feedback, images, categories         → Moodle XML
```

## Frequently asked questions

### What is Aiken format in Moodle?

Aiken is a plain text format Moodle imports directly. A question is written as one block: the stem on the first line, the choices prefixed with a capital letter and a full stop or a bracket, then a final ANSWER: line naming the correct letter, in capitals. A blank line separates two questions. It only handles single-answer multiple choice.

### How do I convert a Word document to a Moodle quiz?

Drop the .docx file into the Word tab of this page. The document is read in your browser: paragraphs become stems and choices, and answers written in bold are recognised as the correct ones. Check the cards it shows, fix whatever needs fixing, then download the Aiken, GIFT or Moodle XML file.

### Can Aiken format have multiple correct answers?

No. The ANSWER line carries a single letter, and Moodle imports every Aiken question as a single-answer one. A question with several correct answers has to go through GIFT, which spreads the weights, or Moodle XML, which sets single to false and distributes the fractions. The converter flags the affected question before you export.

### What is the difference between Aiken and GIFT?

Aiken only expresses single-answer multiple choice, in five rules you learn in a minute. GIFT also expresses multiple answers, true/false, short answers, numerical answers, partial credit and feedback on each choice — at the price of six characters to escape: ~ = # { } and the colon. Aiken to move fast, GIFT as soon as you need more.

### How do I fix "ANSWER line not found"?

That error means Moodle found no answer line in a block. Three causes: the word ANSWER is not in capitals, the line is missing, or the blank line between two questions disappeared and Moodle merged two blocks. Drop the file here: the question without an answer is flagged with its line number.

### Does Moodle import Excel questions?

Moodle does not: it accepts neither .xlsx nor .xls. This page does: drop the workbook and its first sheet is read directly, with no CSV export step in between. The converter guesses the delimiter, the choice columns and the answer column, lets you correct what it guessed, then writes the Aiken, GIFT or Moodle XML file Moodle imports. Formulas are not recalculated — the value on screen is what is read — and a date arrives as a number.

### Is my file uploaded to a server?

No. Reading, converting and downloading all happen inside your browser; the file never leaves your computer and nothing is stored. That is also why the tool keeps working on a school network that blocks outside services.

## Other tools

## What if there were no file to convert at all?

Evalmee imports your questions from Word, Excel, plain text or a Moodle XML file, runs the exam and grades it — with no conversion step.
