Free CSV to DBF — pure JS — QGIS · ArcGIS · FoxPro

Convert CSV to DBF
dBASE binary,
in your browser.

Free CSV to dBASE .dbf converter. Creates a real binary dBASE III file in pure JavaScript — no libraries, no server. Compatible with QGIS, ArcGIS, LibreOffice Base, FoxPro and Shapefile attribute tables. Your data never leaves your device.

Your data never leaves your browser
Pure JavaScript — no libraries
QGIS & ArcGIS compatible
Shapefile attribute table
Always free
CSV to DBF Converter  Pure JavaScript
No external libraries. The dBASE III binary format is written directly in JavaScript — same as the CSV to Parquet tool.
Drop your CSV file here
.csv, .txt or .tsv — creates a real dBASE III .dbf binary
 DBF file ready

      
DBF field types generated

CSVShift auto-detects the appropriate dBASE field type for each CSV column.

C
Character
Fixed-length text string. Used for names, codes, descriptions and any non-numeric data.
Max length: 254 characters
N
Numeric
Fixed-width numeric value, stored as ASCII digits. Detected when all values in a column are numbers.
Max: 18 digits, 4 decimal places
L
Logical
Single byte true/false flag. Detected when all values are T/F/Y/N/true/false/yes/no.
Stored as T or F (1 byte)
DBF field name rules

dBASE III field names have strict constraints — CSVShift handles them automatically.

Constraints
  • Maximum 10 characters
  • Uppercase only (auto-converted)
  • Letters, digits, underscore only
  • Must start with a letter or underscore
  • No spaces or special characters
  • All names must be unique
What CSVShift does automatically
  • Converts to UPPERCASE
  • Replaces invalid chars with _
  • Truncates names to 10 characters
  • Prefixes numeric starts with _
  • Deduplicates by appending numbers
  • Shows field map in the result
How the dBASE III binary format works

Structure of a .dbf file — written entirely in JavaScript.

1
32-byte file header

The header stores version (0x03 = dBASE III), last-modified date, record count, header size in bytes, and record size in bytes — all as little-endian binary integers. The header tells any DBF reader exactly where records start and how large each one is.

2
32-byte field descriptors

One 32-byte block per column: field name (11 bytes, null-padded), field type byte (C/N/L), 4 reserved bytes, field length, decimal count, and 14 more reserved bytes. Terminated by a 0x0D byte. This is the DBF "schema" — defines how to read each field in every record.

3
Fixed-width records

Each record starts with a 0x20 space byte (deletion flag), followed by each field value padded or truncated to its fixed length: C fields left-padded with spaces, N fields right-padded, L fields as a single T or F byte. Every record is the same size — enabling O(1) random access by record number.

CSV to DBF in Python

For scripting and GIS workflows.

Python — dbf library
import csv, dbf # Read CSV with open('data.csv') as f: reader = csv.DictReader(f) rows = list(reader) # Define schema: 'name C(50); age N(3,0); active L' schema = 'name C(50); score N(10,2); active L' table = dbf.Table('output.dbf', schema) with table.open(dbf.READ_WRITE): for row in rows: table.append((row['name'], float(row['score']), row['active'].lower() in ('true','yes','1')))
Requires: pip install dbf. The dbf library writes dBASE III/IV compatible files readable by QGIS, ArcGIS and LibreOffice Base.
QGIS — import CSV as Shapefile attribute table
# In QGIS Python console: from qgis.core import QgsVectorFileWriter, QgsFields, QgsField from PyQt5.QtCore import QVariant # Or use Layer menu → Add Layer → Add Delimited Text Layer # Then: Layer → Save As → ESRI Shapefile (creates .dbf automatically)
QGIS creates the .dbf file automatically when you save a layer as Shapefile. Use CSVShift's .dbf for standalone attribute data without geometry.
When do you need CSV to DBF?
GIS and Shapefile attribute data

Shapefiles consist of .shp (geometry), .shx (index) and .dbf (attributes). When you have CSV attribute data that needs to be joined with existing geometry, creating a .dbf directly allows attaching it to a .shp without going through a full GIS import workflow.

Legacy business applications

Older ERP systems, accounting software and business applications built on dBASE, Clipper or FoxPro accept .dbf files as their native import format. Converting a modern CSV export to .dbf enables data import into these legacy systems without custom connectors.

LibreOffice Base

LibreOffice Base can open .dbf files directly as database tables. Converting a CSV to .dbf produces a file that LibreOffice Base opens as a table with correct field types, sortable and queryable with SQL — without setting up a full database connection.

Remote sensing and surveying

GPS and surveying equipment, LiDAR processing software and many remote sensing tools output and consume DBF files for point cloud attributes, GPS waypoints and survey measurements. CSV-to-DBF is a common step in field data workflows.

Related CSV tools
Popular searches
csv to dbf converter convert csv to dbf csv to dbf online csv to dbf free convert csv to dbf free csv to dbase csv to shapefile dbf csv to dbf python csv to dbf qgis excel csv to dbf create dbf from csv csv to foxpro dbf

dBASE III binary
written in your browser. No libraries.

CSVShift writes the dBASE III binary format directly in JavaScript — the same approach used for the CSV to Parquet tool. The 32-byte file header, 32-byte field descriptors, fixed-width records and EOF marker are all assembled in a Uint8Array and downloaded as a genuine .dbf file. No SheetJS, no dbfjs, no external dependencies.

The output passes validation in QGIS, ArcGIS, LibreOffice Base and dbfread (Python). Field names are sanitised to the dBASE 10-character uppercase constraint automatically.

Pure JavaScript binary writer
dBASE III format implemented from spec — no external libraries. Same approach as the CSV to Parquet tool.
Field schema preview
The result shows the complete field map — name, type and length — so you can verify before using in GIS tools.
Auto field name sanitisation
Long names, spaces and special characters are automatically converted to valid dBASE field names — no manual renaming.
Free, no conditions
No row limit, no watermark, no account. Funded by display advertising only.
Frequently asked questions
How do I convert CSV to DBF?
Upload your CSV to CSVShift, enable type detection if your data has numbers, and click Create DBF File. Download the .dbf and open it in QGIS, ArcGIS, LibreOffice Base or any dBASE-compatible application. The field map is shown in the result so you can verify field names and types before use.
What is a DBF file?
DBF (dBASE File Format) is a binary database format dating from the 1980s. It is still widely used as the attribute table component of Shapefiles (the .dbf file accompanies .shp and .shx), and by legacy applications built on dBASE, Clipper and FoxPro. Most GIS software — QGIS, ArcGIS, MapInfo — reads and writes .dbf files natively.
Why are my field names truncated or changed?
The dBASE III format limits field names to 10 characters, uppercase, with only letters, digits and underscores. CSV column headers that exceed 10 characters are truncated; spaces and special characters are replaced with underscores; duplicate names are suffixed with numbers. The result preview shows the complete field map so you can see the final names.
Is my data safe when converting CSV to DBF online?
Yes. The entire conversion runs in your browser in pure JavaScript. Your CSV is never uploaded to any server. Open the Network inspector during conversion — zero outbound data requests are made.