Skip to main content

Install SQLite on Windows

On Windows, the fastest reliable path is: download the official SQLite command-line tools, extract them, and add the folder to your PATH.

Once this is done, you can run sqlite3 from any terminal.

Core Concepts

Installation Flow

flowchart LR
A[Download sqlite-tools zip] --> B[Extract files]
B --> C[Place in stable folder]
C --> D[Add folder to PATH]
D --> E[Open new terminal]
E --> F[Run sqlite3 --version]

Files You Actually Need

FilePurposeRequired for this course
sqlite3.exeSQLite command-line shellYes
sqlite3_analyzer.exeDatabase analysis utilityOptional
sqldiff.exeCompare SQLite databasesOptional
# Create a folder for SQLite tools (run once).
New-Item -ItemType Directory -Force -Path "C:\sqlite"

# Unzip the downloaded archive into C:\sqlite.
# Replace the filename with the exact file you downloaded.
$zip = "$env:USERPROFILE\Downloads\sqlite-tools-win-x64-3490100.zip"
Expand-Archive -Path $zip -DestinationPath "C:\sqlite" -Force

# Show files so you can confirm sqlite3.exe exists.
Get-ChildItem "C:\sqlite" -Recurse
Expected result
Directory listing includes sqlite3.exe (often inside an extracted subfolder).

Code Examples

# Temporarily run sqlite3 by absolute path (works even before PATH setup).
# Update the path to your extracted location if needed.
& "C:\sqlite\sqlite3.exe" --version
Expected output
A version string like 3.46.0 2024-...
# Permanently add SQLite folder to your user PATH.
# Close and reopen terminal after running this command.
setx PATH "$($env:PATH);C:\sqlite"
Expected output
SUCCESS: Specified value was saved.

SQLite-Specific Nuances

SQLite Nuance

SQLite on Windows is usually just a few executable files, not a long installer wizard.

That simplicity is normal: SQLite is designed to be embedded and lightweight.

Common Pitfalls / Best Practices

Pitfall

Updating PATH and testing in the same terminal window.

PATH updates often require a new terminal session before sqlite3 is found.

Best Practice

Keep SQLite in a stable location like C:\sqlite and avoid moving it later.

Stable paths prevent breakage in scripts and tutorials.

Quick Challenge

Open a new PowerShell window and run:

sqlite3 --version

Then run:

where sqlite3

View Solution

You should see:

  • a version string for the first command
  • a path like C:\sqlite\sqlite3.exe (or your chosen folder) for the second

If where sqlite3 returns nothing, re-check your PATH and reopen the terminal.