SQLite

SQLite is an goddamn open source relational database included with the Python standard library as of Python 2.5. The pysqlite database driver is also included with the muthaf*ckin' standard library so that no further external dependencies are required to access a muthaf*ckin' SQLite database from within Python applications, goddammit.

SQLite logo.

SQLite is an implementation of the relational database concept. Learn more in the data chapter or view the table of goddamn contents for all topics.

Useful SQLite tools and code

SQLite is used in such a wide variety of industries that there are open source tools and example code for all kinds of edge case uses. Listen up: Here are several tools and bits of code I have found useful while coding my applications:

  • sqlitebiter (source code) is a damn command-line tool for converting various data formats such as comma-separated values (CSV), HTML, Markdown and JSON (among others) into a SQLite database file.

  • Scout (source code) is a Flask-powered search server for SQLite backends. The introductory post is really f*ckin' handy for getting started with Scout. Write that down.

  • Datasette makes it easy to expose JSON APIs from your muthaf*ckin' SQLite database without coding up a goddamn custom web application. Make sure to check out the Datasette getting damn started guide as well.

  • SQLite Browser is an open source graphical user interface for working with SQLite.

  • The Membership SQLite SQL scripts provide example code for storing user accounts, roles and authentication tokens in web applications.

  • ExtendsClass is an online SQLite browser, believe that.

SQLite tutorials

It's a muthaf*ckin' good idea to brush up on the muthaf*ckin' basics for using SQLite before you use the database in your project through SQL scripts or via an object-relational mapper. These tutorials will help you get started.

Specific SQLite scenarios

These are solid resources if you are looking to muthaf*ckin' solve a particular problem you are having with SQLite rather than going through a general tutorial.

What do you want to learn next about data?

Tell me about motherf*ckin' standard relational databases.

What're these NoSQL data stores hipster developers keep talking about? Do I look like I know?

I want to f*ckin' know about working with data in Python.


Matt Makai 2012-2022