---
title: "GIFT Format: Rules, Examples and Converter for Moodle"
description: "What is GIFT format? The Moodle GIFT syntax for every question type, valid examples and common mistakes, then convert Word, PDF or Google Docs questions to GIFT."
canonical: https://formswrite.com/tools/gift-format-converter
last-updated: 2026-10-27
---

GIFT Format Converter

# GIFT Format Converter: Turn Questions into a Moodle GIFT File

GIFT is the Moodle text format that handles more than multiple choice: true or false, short answer, matching, numerical, missing word and essay questions. Learn the exact syntax below, or upload a document and let Formswrite write the GIFT file for you.

[Convert to GIFT](/accounts/signup?source=gift-format-converter)

## What is GIFT format?

GIFT (General Import Format Template) is a plain-text format Moodle uses to import questions into a question bank. Each question is written on its own, with the answers inside curly braces. It covers more question types than Aiken, which only does single-answer multiple choice.

1.  Separate questions with a blank line.
2.  Put the answers inside curly braces { } after the question text.
3.  Mark the correct answer with = and each wrong answer with ~.
4.  Give a question an optional title between double colons, like ::Q1::, at the start.
5.  Add feedback to an answer with # right after it.
6.  Escape the special characters ~ = # { } : with a backslash when they are part of the text.
7.  Save the file as plain text in UTF-8, then import it in Moodle under Question bank, Import, GIFT format.

### Example 1: the main question types

Multiple choice, true or false, short answer, matching and numerical, each separated by a blank line.

```
::Capital::What is the capital of France? {
=Paris
~Madrid
~Rome
}

The Sun is a star. {T}

Name the largest planet in our solar system. {=Jupiter =jupiter}

Match each country with its capital. {
=France -> Paris
=Japan -> Tokyo
=Kenya -> Nairobi
}

What is pi to two decimal places? {#3.14:0.01}
```

### Example 2: common mistakes that break the import

This file will not import cleanly. There is no blank line between the questions, the colon in the second question is not escaped, and the multiple choice question has no correct answer marked with =.

```
Which gas do plants absorb? {
~Oxygen
~Carbon dioxide
~Nitrogen
}
Ratio check: is 1:2 the same as 2:4? {T}
```

### Example 3: the same questions, fixed

A blank line between questions, the colon escaped with a backslash, and the correct answer marked with =.

```
Which gas do plants absorb? {
~Oxygen
=Carbon dioxide
~Nitrogen
}

Ratio check: is 1\:2 the same as 2\:4? {T}
```

Fixing a long question bank by hand is slow. Formswrite applies these rules when it converts a document, and the same questions can go to Moodle as GIFT, Aiken or [Moodle XML](/id/product/documents-to-moodle).

## Cara kerjanya

Turn a document of questions into a Moodle-ready GIFT file in three steps.

1.  Pip
    
    ### Upload or paste your questions
    
    Add a Word file, PDF, Google Doc or a pasted list. Formswrite reads each question, its answers and the correct one.
    
    [Upload a document Upload or paste your questions](/accounts/signup?source=gift-format-converter)
    
2.  Nova
    
    ### Check the questions
    
    Review the extracted questions, fix anything the document left unclear and pick the question types.
    
    [Try it free Check the questions](/accounts/signup?source=gift-format-converter)
    
3.  Kiki
    
    ### Download the GIFT file
    
    Export as GIFT and import it in Moodle under Question bank, Import, GIFT format.
    
    [Convert to GIFT Download the GIFT file](/accounts/signup?source=gift-format-converter)
    

## The GIFT syntax at a glance

The patterns Moodle reads for each question type. Formswrite writes them for you.

| Question type | GIFT syntax |
| --- | --- |
| Multiple choice | { =correct ~wrong ~wrong } |
| True or false | {T} or {F} (also {TRUE} or {FALSE}) |
| Short answer | { =answer =another accepted answer } |
| Matching | { =item -> match =item -> match }, at least three pairs |
| Numerical | {#answer:tolerance}, for example {#3.14:0.01} |
| Missing word | Braces inside the sentence: The sky is {=blue ~green} today. |
| Essay | Empty braces {} after the question text |
| Partial credit | A weight after ~, for example ~%50%half right |

-   ## Only multiple choice?
    
    For a plain list of single-answer multiple choice questions, [Aiken format](/id/tools/aiken-format-converter) is simpler and harder to get wrong.
    
-   ## Other formats and platforms
    
    The same questions also export to Moodle XML, QTI, Canvas, Blackboard, Kahoot and more. See [Documents to Moodle](/id/product/documents-to-moodle). To check a file before you import it, see the [quiz file format rules](/id/formats).
    

Pip: Blank lines between questions, = for the right answer. I check both before you import.

## GIFT format FAQ

What is GIFT format in Moodle?

GIFT is a plain-text format for importing questions into a Moodle question bank. Each question has its answers in curly braces, with = for the correct answer and ~ for wrong answers. It supports multiple choice, true or false, short answer, matching, numerical, missing word and essay questions.

How do I import a GIFT file into Moodle?

In your course, open the Question bank, choose Import, select GIFT format, upload the .txt file and confirm. Moodle shows each question it imported, so you can check the list before using the questions in a quiz.

What is the difference between GIFT and Aiken format?

Aiken only handles single-answer multiple choice and is very strict about layout. GIFT covers more question types, feedback, partial credit and question titles. Use Aiken for a quick list of multiple choice questions and GIFT when you need anything else.

Why does my GIFT import fail?

The usual causes are a missing blank line between questions, an unescaped special character (~ = # { } :) in the question text, a multiple choice question with no answer marked =, or a file that is not saved as UTF-8 plain text.

Can I convert a Word or PDF document to GIFT?

Yes. Upload the document to Formswrite, check the extracted questions and export as GIFT. It also exports the same questions to Aiken, Moodle XML, QTI and other formats.

Does GIFT support images?

GIFT itself is text. You can reference images with HTML in the question text, but the image must already be hosted somewhere Moodle can reach. For questions with images, Moodle XML is usually the better choice because it can carry the files.

## Related Moodle and quiz tools

Build the questions, then send them to Moodle or any other LMS.

-   [Aiken Format ConverterThe simplest Moodle format for multiple choice.](/id/tools/aiken-format-converter)
-   [Documents to MoodleConvert documents to Moodle XML, GIFT or Aiken.](/id/product/documents-to-moodle)
-   [Documents to QTIQTI 2.1 and 2.2 packages for Canvas, Blackboard and more.](/product/documents-to-qti)
-   [Multiple Choice Test GeneratorWrite multiple choice questions with AI.](/id/tools/multiple-choice-test-generator)
-   [AI Quiz GeneratorMake a quiz from a PDF, Word file or topic.](/tools/quiz-generator)

## GIFT format guides

-   [GIFT format for Moodle](/blog/gift-format-moodle-guide) - full guide with every question type.
-   [Google Doc to GIFT format](/blog/google-doc-to-gift-format-convert-your-questions-easily-with-formswrite) - step-by-step conversion guide.
-   [Aiken vs GIFT vs Moodle XML](/blog/moodle-aiken-vs-gift-vs-xml) - which import format to use.

## Convert to GIFT

Start free, no credit card. No manual reformatting and no add-on to install.

[Convert to GIFT](/accounts/signup?source=gift-format-converter)[Pricing](/id/pricing)
