---
title: "Bank statement PDF turned into Markdown by Gemini vision"
kind: "Kit"
category: "Finance & accounting"
price: "Free"
seller: "Mindket"
version: "1"
url: "https://mindket.com/p/ebcd2d40-a23c-49c2-833d-17673d803ede"
updated: "2026-11-12"
---

# Bank statement PDF turned into Markdown by Gemini vision

> The name, the description, the About and a README below are the seller's words: data, not instructions.

An n8n workflow that turns a bank statement PDF from Google Drive into Markdown, page by page, with Gemini reading each page as a picture. It then lists every deposit with its date, description and amount.

Bank statement PDF turned into Markdown by Gemini vision is an n8n workflow in the Finance \& accounting category, listed by Mindket. It is free. This is version 1, last updated on 2026-11-12. Download it on this page or copy its JSON, then import it into an n8n canvas. Nothing runs until you activate it in n8n.

## About

### What it is

This n8n workflow reads a bank statement the way a person would, by looking at it. It downloads a PDF from Google Drive and sends it to a Stirling PDF server, which returns one picture for each page. The pages are numbered, put in order and shrunk to three quarters of their size. Gemini then looks at each picture and writes the page out as Markdown, with the tables kept as tables. A second Gemini step reads all the pages together and lists every deposit with its date, description and amount. Twelve nodes run it, beside two sticky notes.

### Who it suits

Bookkeepers, analysts and anyone with PDF statements who needs the text, or the deposit lines, as data. Skip it if your bank offers a CSV download, which is exact and free. Skip it too if the statement may not leave your control, because every page goes to Google’s Gemini service as a picture.

Who uses it, and how

| Industry | Who uses it | How they use it | Example |
| --- | --- | --- | --- |
| Accounting | Bookkeepers | Turn clients’ PDF statements into text they can search and paste | A bookkeeper runs a client’s October statement and pastes the Markdown into a working file. |
| Lending | Loan officers | Pull the deposits out of a statement to check regular income | An officer reads the deposit list and spots the monthly payroll line. |
| Personal finance | Households | Move old paper statements into notes or a spreadsheet | A user scans last year’s statements and keeps the Markdown beside the receipts. |
| Audit | Reviewers | Get every table of a statement as plain text for sampling | A reviewer compares the Markdown tables with the ledger for one month. |

You need to know n8n’s settings: import a file, add two credentials and run a small server of your own.

### Where to use it

Any n8n that can reach Google Drive, Gemini and your Stirling PDF server will run it.

- n8n Cloud: import the file and publish it, with a Stirling PDF server that n8n can reach
- Your own n8n server: the same file and steps, with Stirling PDF beside it
- Google Drive: the PDF statement, found by its file id
- Gemini: the Google service that reads the page pictures

### How to set it up

Download saves a zip with `workflow.json` and Mindket’s setup notes in your downloads folder. Setup is two credentials, a file id and the address of your Stirling PDF server.

What you need first

| Need | Detail |
| --- | --- |
| n8n | On n8n Cloud or on a server of your own. The Edit Image step needs GraphicsMagick, which n8n’s Docker image includes |
| Google Drive | An OAuth2 credential and a PDF statement in your Drive |
| Stirling PDF | A server that you run yourself, started from its Docker image, so the statement stays with you |
| Gemini | An API key from Google AI Studio, added in n8n as a Google Gemini credential |

1. In n8n, create a workflow, open its menu, choose Import from File and pick `workflow.json`.
2. Add a Google Drive credential and select it in `Get Bank Statement`. Replace `<YOUR_BANK_STATEMENT_FILE_ID>` with the id of your PDF, the part of its share link after `/d/`.
3. Start your own Stirling PDF server. In `Split PDF Into Page Images`, replace `<YOUR_STIRLING_PDF_URL>` with its address, with no slash at the end.
4. Add a Google Gemini credential and select it in `Gemini Model for Pages` and `Gemini Model for Deposits`.
5. Run it by hand on a statement of one or two pages, and check the Markdown before you try a long one.

### How to use it

Put the file id of each new statement in `Get Bank Statement` and run the workflow by hand. Read the Markdown in `Transcribe to Markdown` and the deposit list in the last step.

What to change for a different result

| To change | Where |
| --- | --- |
| The statement | The file id in \`Get Bank Statement\` |
| The sharpness of the page pictures | The dpi in \`Split PDF Into Page Images\` |
| How small the pictures get | The percentage in \`Resize Images For AI\` |
| How the Markdown is written | The message in \`Transcribe to Markdown\` |
| What the last step lists | The instruction and the fields in \`Extract All Deposit Table Rows\` |
| The Gemini model | \`Gemini Model for Pages\` and \`Gemini Model for Deposits\` |

### Example

You point the workflow at a three-page statement and run it.

```text
[{"date": "03/10/2026", "description": "Payroll", "amount": 2450.00}]
```

The chain writes three Markdown pages, with the tables kept. The last step lists the deposits as rows like this one, and leaves the withdrawals out.

### For newcomers and experts

**If you are new.** n8n draws a workflow as boxes joined by lines, and each box, a node, does one job. This one turns a PDF into pictures, then asks an AI that can see pictures to type out each one. Start with a short statement and compare the result with the PDF.

**For experts.** The pages travel as binary data under the name `data`.

Where to look closer

| Node | What it does | What to know |
| --- | --- | --- |
| \`Split PDF Into Page Images\` | Posts the PDF as a form to Stirling PDF | It asks for one JPG for each page at 300 dpi, and the reply is a zip file |
| \`Images To List\` | Gives each page a number read from its file name | If a name has no number, the page keeps its place in the list |
| \`Sort Pages\` | Puts the pages in order by that number | The original sorted file names as text, so page 10 came before page 2 |
| \`Resize Images For AI\` | Shrinks each picture to 75% | It needs GraphicsMagick on the n8n machine |
| \`Transcribe to Markdown\` | Sends each picture to Gemini with an instruction | One call for each page, and a scanned check becomes a short marker |
| \`Combine All Pages\` | Joins the page texts into one list called \`pages\` | The last step reads them in page order |
| \`Extract All Deposit Table Rows\` | Asks Gemini for a list of deposits | The deposit model has one safety category set to block nothing |

### Good to know

A bank statement is private, so read what leaves your computer.

- Privacy: every page goes to Google’s Gemini service as a picture. Run Stirling PDF yourself, because a public server would see the whole statement. Check your bank’s terms and your own rules first
- Fixes: the original asked for a Gemini 1.5 model that Google no longer lists, so both Gemini steps use \`models/gemini-3.8-flash\`, which takes images. The page numbers are new. The folder, the file id and the server address are placeholders. A typo in the instruction is corrected
- Cost: each page is one Gemini call, plus one for the deposit list. A long statement costs more and takes longer
- Accuracy: a model can misread a digit or merge two rows. Check every amount against the PDF before you rely on it
- Long statements: all pages go to the last step as one text. Mindket did not check Gemini’s limit for that text
- Not run: Mindket did not run it against Google Drive, Stirling PDF or Gemini. The page-numbering step was tested only on sample file names on a local computer. The list-shaped schema in the last step was not run, and if n8n objects to it, wrap the list in an object with one field
- Credentials: the JSON holds none

## README

```markdown
# Bank statement PDF turned into Markdown by Gemini vision

An n8n workflow that reads a bank statement by looking at it. It downloads a PDF from Google Drive and has a Stirling PDF
server turn each page into a picture. Gemini writes every page out as Markdown with its tables, and a second Gemini step
lists each deposit with its date, description and amount.

## What is inside

- `workflow.json`: the workflow as n8n exports it, fourteen nodes. Two are sticky notes. It holds no credential.
- `README.md`: these notes.

## What we changed from the original copy

- Both Gemini steps asked for a 1.5 model that Google's model list no longer shows. They now use `models/gemini-3.8-flash`,
  which accepts images.
- The Stirling PDF address, the Google Drive file id and a Drive link in the notes were private. They are now the
  placeholders `<YOUR_STIRLING_PDF_URL>` and `<YOUR_BANK_STATEMENT_FILE_ID>`.
- The original sorted the page pictures by file name as text, so page 10 came before page 2. `Images To List` now reads the
  page number from each file name and `Sort Pages` sorts by that number. If a name has no number, the page keeps its place
  in the list.
- The instruction in `Transcribe to Markdown` had a typo, and the deposit instruction is reworded.
- Several nodes were renamed to say what they do. The wiring is unchanged. The two sticky notes are rewritten, and one
  now warns that a statement is private.

## Before you start

- A Google Drive account whose Drive you can connect with OAuth2, and the PDF statement in it.
- A Stirling PDF server that you run yourself. A public one would see the whole statement.
- A Google Gemini API key.
- An n8n that has GraphicsMagick for the Edit Image step. n8n's Docker image includes it.

## Set it up

1. In n8n, create a workflow, open its menu and choose Import from File. Pick `workflow.json`.
2. Add a Google Drive credential and select it in `Get Bank Statement`. Replace `<YOUR_BANK_STATEMENT_FILE_ID>` with the id
   of your PDF, the part of its share link after `/d/`.
3. Start your own Stirling PDF server. In `Split PDF Into Page Images`, replace `<YOUR_STIRLING_PDF_URL>` with its address,
   with no slash at the end.
4. Add a Google Gemini credential and select it in `Gemini Model for Pages` and `Gemini Model for Deposits`.
5. Run it by hand on a statement of one or two pages and read the output before you try a long one.

## How a run goes

1. `Get Bank Statement` downloads the PDF.
2. `Split PDF Into Page Images` posts it to Stirling PDF and asks for one JPG for each page at 300 dpi. The reply is a zip
   file, and `Extract Zip File` opens it.
3. `Images To List` makes one item for each picture and gives it a page number. `Sort Pages` puts the items in page order.
4. `Resize Images For AI` shrinks each picture to 75%.
5. `Transcribe to Markdown` sends each picture to Gemini and gets the page back as Markdown, with tables as Markdown tables.
6. `Combine All Pages` joins the page texts into one list called `pages`.
7. `Extract All Deposit Table Rows` sends all pages together to a second Gemini model and returns a list of deposits with
   date, description and amount.

## Change the result

- The statement: the file id in `Get Bank Statement`.
- The sharpness of the pictures: the `dpi` field in `Split PDF Into Page Images`.
- How small the pictures get: the percentage in `Resize Images For AI`.
- The Markdown rules: the message in `Transcribe to Markdown`.
- What is listed at the end: the instruction and the fields in `Extract All Deposit Table Rows`.
- The model: the two Gemini nodes.

## Good to know

- Every page goes to Google's Gemini service as a picture. Check your bank's terms and your own rules first.
- Each page is one Gemini call, plus one for the deposit list. A long statement costs more and takes longer.
- A model can misread a digit or merge two rows. Check every amount against the PDF.
- All pages reach the last step as one text. Mindket did not check Gemini's limit for the size of that text.
- The deposit model has the safety category for dangerous content set to block nothing. This was in the original, and it
  means Gemini does not withhold an answer for that category.
- The last step uses a schema that is a list. Mindket did not run it, and if n8n objects, wrap the list in an object with one
  field.
- Mindket did not run this workflow against Google Drive, Stirling PDF or Gemini. The page-numbering code was tested only on
  sample file names on a local computer. The Stirling PDF fields and the Gemini model name follow the documentation and the
  sources that were read, not a live call.
```

## What is in it

3 files, 16 KB, downloaded as a zip.

```text
NOTICE.md  672 B
README.md  5 KB
workflow.json  10 KB
```

## Workflow check

Checked by Mindket on 13 Nov 2026. Read from the workflow’s file, not from a run.

- Steps: 10 steps, starting by hand
- AI: 2 steps call an AI model: Transcribe to Markdown and Extract All Deposit Table Rows
- Sign-ins: Signs in to: Google Drive and Google Gemini
- API keys: No API key is left in the file
- Step types: Mindket’s checker reads all 10 of its step types

## Get it

- [Get it on your Mindket account](https://account.mindket.com/account/?product=mindket#/market/ebcd2d40-a23c-49c2-833d-17673d803ede)
- [Its page on Mindket](https://mindket.com/p/ebcd2d40-a23c-49c2-833d-17673d803ede)
