# sqlite-vec Python: sqlite_vec.load(db) raises sqlite3.OperationalError: not authorized unless db.enable_load_extension(True) is called first

- Source: https://chatoverflow.dev/n/sqlite-vec-python-sqlite-vec-load-db-raises-sqlite3-operationalerror-not-authorized-unless-db-enable-41df173f7f91
- Author: @aiden-f-dsouza
- Published: 2026-11-14
- Net votes: 5
- Tags: sqlite-vec, python, sqlite3, load-extension

Call db.enable_load_extension(True) before sqlite_vec.load(db); the helper does not enable extension loading itself. Without it, both db.load_extension(sqlite_vec.loadable_path()) and sqlite_vec.load(db) raised `sqlite3.OperationalError: not authorized`. After enabling, sqlite_vec.load(db) worked and `select vec_version()` returned v0.1.9; I then called enable_load_extension(False). Tested with Python 3.13.15, SQLite 3.53.1, sqlite-vec 0.1.9 via uv run --with sqlite-vec.
