Home › TXT to Google Form

TXT to Google Form: Turn a .txt Question File Into a Quiz Without Re-typing

Updated November 12, 2026 · ~10 min read

"txt to google form" and "how to import text file to google forms" come from the same situation: your question bank is a plain .txt file from Notepad, an LMS export or a colleague, and Google Forms will not read it. There is no Upload .txt button. The reliable route is to let a converter parse the text into structured rows and write the form under your account — no manual reformatting, no re-typing. This guide covers what actually needs cleaning (encoding and line endings), a runnable normaliser, and the mistakes that lose options or the answer key.

No manual cleanup needed for structure: You do not have to turn the .txt into a spreadsheet by hand. A converter parses stems, options and answers into fixed columns and writes the Google Form. The only things worth fixing in the .txt first are the encoding and line endings — those are file-level problems, not question-level editing.

Why Google Forms cannot read a .txt file

Forms accepts a form you build in its editor, or a form duplicated from Drive. It does not ingest text, CSV, Word or PDF files as questions. So "can I upload a txt file to a Google Form" has a clear answer: not directly. Something must parse the file into item objects — either your own script or a converter that does the whole job.

Plain text is actually a good source: unlike a scanned PDF there is no OCR error, and unlike a two-column Word layout there is no reading-order ambiguity. The main risks are file-level (encoding, line endings) and pattern-level (how options and the answer are written).

The three file-level problems (and their fixes)

ProblemSymptomFix
Wrong encoding (GBK / Windows-1252 saved as UTF-8)Accented or CJK characters become ???? or mojibakeDetect and re-save as UTF-8; the normaliser below does it
UTF-8 BOMFirst line starts with an invisible \ufeff; the first question number failsRead with utf-8-sig
CRLF / mixed line endingsOptions merge into the stem, or blank lines appear mid-questionNormalise \r\n and \r to \n

Runnable normaliser: .txt → clean UTF-8 text

import chardet  # pip install chardet
import re

def read_txt(path):
    raw = open(path, "rb").read()
    enc = chardet.detect(raw)["encoding"] or "utf-8"
    if enc.lower() in ("ascii", "us-ascii"):
        enc = "utf-8"
    text = raw.decode(enc, errors="replace")
    text = text.lstrip("\ufeff")           # strip BOM
    text = text.replace("\r\n", "\n").replace("\r", "\n")  # CRLF
    text = re.sub(r"[ \t]+$", "", text, flags=re.M)  # trailing ws
    text = re.sub(r"\n{3,}", "\n\n", text)          # collapse blanks
    return text.strip() + "\n"

clean = read_txt("questions.txt")
open("questions_clean.txt", "w", encoding="utf-8", newline="\n") \
    .write(clean)
print("ready to upload:", len(clean.splitlines()), "lines")

That is the whole "manual cleanup" you should ever need — and it is optional if your file is already UTF-8 with normal line breaks. If your text uses a numbered stem with A–E options and an Answer: X line, the MCQ parser in Import Multiple Choice Questions into Google Forms turns it into fixed columns; if you would rather not run code, upload the .txt straight to the converter and it does the parse.

What the importer needs from your text

One question per block, in a repeatable pattern:

1. Which planet is closest to the Sun?
A) Mercury
B) Venus
C) Earth
D) Mars
Answer: A
Marks: 1

2. The Earth is flat. True or false?
A) True
B) False
Answer: B
Marks: 1

The converter maps this into Number / Type / Stem / Option A–E / Answer / Marks / Image URL and writes a form you own. Consistent separators matter more than pretty formatting. If your file instead has one question per line with comma-separated fields, see CSV to Google Forms; for pasted text rather than a file, Text to Google Form covers the paste workflow.

TXT to Google Form in 5 steps

Troubleshooting

1

Check the file

Confirm it is real plain text, note the encoding and line endings.

2

Normalise (optional)

Run the script: detect encoding, strip BOM, unify line endings.

3

Keep a consistent pattern

Numbered stem, one option per line, Answer/Marks on their own lines.

4

Upload

Let the converter parse into fixed columns and write the form under your account.

5

Verify

Open the form; check the first, middle and last question, then enable quiz mode if needed.

Frequently asked questions

Can I upload a .txt file to a Google Form?

Not directly. Google Forms has no text-file or CSV import for questions; it only builds items in its editor or duplicates an existing Form. To turn a .txt into a quiz you need a script that parses the file, or a converter that parses it and writes the Google Form under your own account.

How do I import a text file into Google Forms without re-typing the questions?

Keep a consistent pattern (numbered stem, one option per line, 'Answer: A' and 'Marks: 1' on their own lines), make sure the file is UTF-8 with normal line endings, then upload it to a converter that maps the text into fixed columns and creates the form. No manual spreadsheet cleanup is required.

Why are characters garbled after importing a .txt?

The file was saved in GBK, Windows-1252 or another legacy encoding but read as UTF-8. Detect the encoding and re-save as UTF-8; strip a UTF-8 BOM if present. The runnable normaliser in this guide does both.

What is the difference between 'txt to Google Form' and 'text to Google Form'?

They describe the same conversion; 'txt' usually means a .txt file on disk (so encoding, BOM and CRLF matter), while 'text' often means pasted plain text. This guide covers the file case; see Text to Google Form for the paste workflow.

Does the answer key survive a .txt import?

Yes, if the source has an explicit answer per question and the destination is in quiz mode with the correct flag attached to the choice. A key listed only at the end of the file must be joined back by question number.

Question importers

ExamParser has a dedicated importer for each source format. Pick the one your questions currently live in — PDF, Word, Excel, Google Sheets or a quiz file — and the questions, options and answer key are carried into a Google Form you own.

Related guides

Upload the .txt and get a finished form

No manual cleanup, no re-typing, no AI inventing questions. Upload the text file you already have and get a Google Form you own, with the questions, options, answer key and marks carried over exactly as written.

Import my questions into Google Forms →