AcademyWorkflowsData and reporting

Import CSV files into PostgreSQL

Data and operations teams that load regular exports from spreadsheets or other systems into a database.

  • Recommendedour rating
  • 3,729views on n8n
Open on n8n.io ↗

Paste it straight onto an n8n canvas with Ctrl+V or Cmd+V.

import-csv-files-from-filesystem-into-postgres.json

Loading the file...

What it does

This n8n template reads a CSV file stored on the server and inserts its rows into an existing PostgreSQL table. It is built for self-hosted setups where n8n can reach the file. The example uses a small test table, and the file path and database name can be changed.

Use cases

  1. 01Load a daily CSV export into a reporting table
  2. 02Move a list of records into a test database
  3. 03Read files from cloud storage instead of the local server

Connects

Postgres

Questions about
Import CSV files into PostgreSQL.

What is Import CSV files into PostgreSQL used for?

Data and operations teams that load regular exports from spreadsheets or other systems into a database. This n8n template reads a CSV file stored on the server and inserts its rows into an existing PostgreSQL table. It is built for self-hosted setups where n8n can reach the file. The example uses a small test table, and the file path and database name can be changed.

How do I import Import CSV files into PostgreSQL into n8n?

Copy the workflow JSON from this page and paste it onto the n8n canvas with Ctrl+V or Cmd+V. Then connect your credentials in each node.

Is Import CSV files into PostgreSQL safe to use?

It passed our automatic scan for credential theft, hidden instructions and risky install commands. Third party open source software. Sabemos AI does not maintain it. Check the code and permissions before you connect it to company data.