Raymond Raymond / SQL Databases

Install SQLite 3 on WSL

event 2021-02-01 visibility 5,388 comment 0 insights toc
insights Stats


Before installing SQLite 3on WSL, please ensure you have WSL enabled on your Windows 10 system. 

Follow Install Windows Subsystem for Linux on a Non-System Drive to install WSL on a non-C drive. 

This tutorial provides steps to install SQLite 3 on WSL Debian distro. You can follow similar steps to install it in other Linux distros. 

Step by step guide

  1. Open Debian distro through WSL command:
    wsl -d Debian
  2. Update Debian packages:
    sudo apt update

    You need to type user password.

  3. Install SQLite 3  using the following command:
    sudo apt install sqlite3

    Type Y to continue when asked.

  4. Wait until the installation is completed. 
  5. Verify SQLite version:
    $ sqlite3 --version
    3.16.2 2017-01-06 16:32:41 a65a62893ca8319e89e48b8a38cf8a59c69a8209

Test SQLite 3

  1. Create a database named test.db using the following command:
    sqlite3 test.db

    The command outputs the following:

    SQLite version 3.16.2 2017-01-06 16:32:41
    Enter ".help" for usage hints.
  2. Check database list using the following command:
    sqlite> .databases
    The output looks like the following screenshot:
  3. Type .exit to exit the CLI.
  4. Run command ls and you will find the file database is created.
    $ ls
More from Kontext
comment Comments
No comments yet.

Please log in or register to comment.

account_circle Log in person_add Register

Log in with external accounts