Home » Blog » Document Joiner » How to Combine PDF Files to RTF as One Document

How to Combine PDF Files to RTF as One Document

author
Written By
Nick Rogers
Published On
December 5th, 2026
Reading Time
10 Minutes Reading
Quick answer: To combine PDF files to RTF, join them into one PDF in number order, open that file in Microsoft Word and save it as Rich Text Format. Without Word, a short Python script can write the text of every document into a single .rtf, but pictures and table grids are left behind.

Meeting minutes, supplier quotes or report chapters often pile up as separate PDFs, yet you need one document you can still edit. RTF suits that job because Word and LibreOffice Writer both open it. Two things decide whether your result is usable: the order of the documents and what survives the trip. For this guide we wrote two short Python scripts and ran them on a short introduction, a budget and a photo document, numbered 1, 2 and 10. One script hands a joined PDF to Word, which we drove through automation. The other writes RTF on its own. We also merged ready-made RTF copies inside Word. Acrobat and the Windows merger weren’t run. Want a separate copy of each document? Follow our guide to turn every PDF into its own RTF.

4 Ways to Combine PDF Files to RTF

Let the things your final document must keep decide the route.

Route What You Keep What You Need
Join script plus Word Table, link, footnote and picture in our run Python and Word
Text-only script Words in the right order Python
Adobe Acrobat Not tested here A paid plan
Windows merger Not tested here A demo or licence

Number Your .pdf Files in Reading Order

Both scripts sort names by their numbers, so 2 lands ahead of 10. Prefix names with 01, 02 and so on if another program lists them letter by letter. Clear drafts out of the folder first, because every .pdf inside it gets joined.

Join the PDFs, Then Save 1 Document in Word

This route lets Word do the format change only once. The script needs PyMuPDF, which you add with pip install --upgrade pymupdf as the PyMuPDF installation page shows. The library carries an AGPL or commercial licence.

Name the script joinpdf.py, put your own folder in place of C:\Docs and start it with Python.

import pathlib
import re

import pymupdf

folder = pathlib.Path(r"C:\Docs")
files = sorted(folder.glob("*.pdf"),
               key=lambda f: [int(t) if t.isdigit() else t for t in re.split(r"(\d+)", f.name.lower())])
joined = pymupdf.open()

for pdf in files:
    with pymupdf.open(pdf) as doc:
        if doc.needs_pass:
            raise SystemExit(f"{pdf.name} needs a password, so nothing was joined.")
        joined.insert_pdf(doc)
    print(pdf.name)    # the joining order

out = folder / "merged"
out.mkdir(exist_ok=True)
joined.save(out / "joined.pdf")
  1. Open joined.pdf from the new merged subfolder in Word.
  2. Accept the conversion notice with OK.
  3. Choose File > Save As and set Rich Text Format (*.rtf).

Our four source pages became a 3-page RTF. All three headings arrived as Heading 1, the budget table and its footnote stayed real, the link stayed clickable and the photo came along. Word also moved the repeated page line into a true header, which didn’t happen when we converted the samples one by one.

Limitations: you need Word. The joined PDF weighed 95 KB and the .rtf about 1.4 MB. Text from the second photo page moved up under the picture, and the footnote divider showed twice. A locked document stops the script before anything is written.

Combine PDF Files to RTF Without Word Using Python

No Word on your machine? This second script reads the text blocks of each document and writes the RTF code itself. Save it as textrtf.py.

import pathlib
import re

import pymupdf


def rtf(text):
    out = []
    for ch in text:
        if ch in "\\{}":
            out.append("\\" + ch)
        elif ord(ch) < 128:
            out.append(ch)
        else:
            data = ch.encode("utf-16-le")
            for i in range(0, len(data), 2):
                out.append(f"\\u{int.from_bytes(data[i:i + 2], 'little', signed=True)}?")
    return "".join(out)


folder = pathlib.Path(r"C:\Docs")
files = sorted(folder.glob("*.pdf"),
               key=lambda f: [int(t) if t.isdigit() else t for t in re.split(r"(\d+)", f.name.lower())])
body = []

for number, pdf in enumerate(files, 1):
    if number > 1:
        body.append(r"\page")
    body.append(r"{\pard\sa200\b\fs32 " + rtf(pdf.stem) + r"\par}")
    with pymupdf.open(pdf) as doc:
        if doc.needs_pass:
            raise SystemExit(f"{pdf.name} needs a password, so nothing was merged.")
        for page in doc:
            for block in page.get_text("blocks"):
                if block[6] == 0:    # text, not a picture
                    line = " ".join(block[4].split())
                    body.append(r"{\pard\sa120\fs22 " + rtf(line) + r"\par}")
    print(number, pdf.name)

out = folder / "merged"
out.mkdir(exist_ok=True)
head = r"{\rtf1\ansi\deff0{\fonttbl{\f0 Calibri;}}"
(out / "merged.rtf").write_text(head + "\n" + "\n".join(body) + "\n}", encoding="ascii")

You get merged.rtf in a merged subfolder, only about 1 KB for our samples. Each document begins on a new page under its file name, and accented words read correctly.

Limitations: table rows turn into plain lines, bullets run together and the link can’t be clicked. Pictures are left out, and the footnote number sticks to the next word. A scanned document contributes nothing but its name.

Combine in Acrobat, Then Convert to RTF

If you subscribe to Acrobat, you can stay inside it. Adobe explains how to combine files into one PDF and, separately, how to save a PDF in rich text format.

  1. Add your documents in the Combine files tool and arrange them.
  2. Click Combine and save the result.
  3. Open the Convert tool and choose Other Format.
  4. Set RTF in the list, then select Convert to RTF.

Your version may word these labels differently. We haven’t tried the sequence.

Use a Windows RTF Merger With Folder Loading

The 4n6 Document Joiner lists RTF among its export types, so your PDFs can be joined without scripts.

  1. Download the demo and run its setup.

    Download Free Demo

  2. Under Open, hover over PDF Files and add documents or a whole folder.
    PDF Files submenu offering Choose Files and Choose Folders
  3. Review what appears in the loaded list.
    Selected PDF Files node with its documents listed alongside
  4. In the Export menu, RTF sits third in the right column. The red box in this picture marks PDF.
    Export menu listing RTF among the saving formats
  5. Browse to a destination, then Save. The panel shown here belongs to a PDF export.
    Location field with Browse and Save buttons on the options panel

Limitations: the free demo stops at 10 files from each folder, according to the product page. Judge its RTF output on your own documents.

Try the Order on a Small Set

Join a handful of documents and page through the .rtf before you load the rest.

Download Free Trial Select a Joiner Licence

Merge RTF Files You Already Have in Word

Are your sources RTF documents rather than PDFs? Word can pull them into one. Microsoft’s page on how to insert a document in Word gives the menu path.

  1. Open a blank document and place the cursor where the text should go.
  2. Go to Insert, select the arrow beside Object and choose Text from File.
  3. Choose the first .rtf, then repeat in your reading order.
  4. Save the result as Rich Text Format, or as PDF if that is your goal.

We ran this through automation with three Word-made copies and a page break between them. Headings, table, link, footnote and picture all arrived. The document ran to 7 pages, several of them blank or nearly blank, so plan some cleanup. The Joiner above also lists RTF as an input type.

5 Checks on Your Merged .rtf

  • Compare the sequence of sections with your file numbers.
  • Click each web link once.
  • Read every table against its source.
  • Remove blank pages before you send the document.
  • Check the size if it has to travel by email.

3 PDF Merging Problems and Their Fixes

Sections Come Out in the Wrong Order

Names without numbers are the usual cause. Do this: put a number in front of every name, then run your script once more.

A Locked Document Halts the Job

Both scripts stop so nothing goes missing unnoticed. Do this: set the locked PDF aside. Where you’re permitted to, you can also remove its password in your PDF program and run the job again.

The Merged Copy Has Blank Pages

This often follows inserted breaks. Do this: show the hidden formatting marks, then remove the spare break. Would one web page serve your readers better? You can merge the PDFs into an HTML page instead.

Frequently Asked Questions

How do I combine PDF files to RTF?

Join them first and save the result from Word, or run the text-only script. The 4n6 Document Joiner lists an RTF export too.

Can I merge RTF files into one document?

Yes. Use Text from File in Word and add them in your reading order.

How do I combine RTF files into one PDF?

Insert them into one Word document, then save that document as PDF.

Can I control the order of my PDFs?

Yes. Numbers at the start of the names decide it in both scripts.

Do tables survive the merge?

They did through the join script plus Word. The text-only script turned rows into lines.

Can I do this without Microsoft Word?

Yes. The text-only script needs only Python, if plain wording is enough.

Why is my merged RTF so large?

Pictures are a likely reason. Our version with the photo reached about 1.4 MB, while the text-only one stayed near 1 KB.

Is it safe to merge PDFs online?

A web service receives copies of your documents. The scripts above work on your own computer.

Which Way to Combine PDF Files to RTF Fits Your Job?

Tables and pictures matter: join first, then save from Word.

Only the wording matters: run the text-only script.

You already pay for Acrobat: combine and convert there.

Scripts aren’t your thing: try the Windows merger demo.

Google Preferred Source