Replace the default mysql CLI with context-aware autocomplete so you stop forgetting column names mid-query.
Save frequently used queries as short aliases and call them back by name to speed up repetitive database work.
Debug a MySQL database on a remote server via SSH with a readable, colored results display instead of raw table output.
Use the LLM integration feature to query your database in plain English using your schema as context.
Requires Python 3.10 or newer. Windows not officially supported, use WSL.
mycli is a command-line tool for working with MySQL databases. MySQL is a widely used database system, and the standard way to interact with it from a terminal is through the official mysql client, which is functional but minimal. mycli replaces that experience with something more helpful: as you type a query, it suggests completions for SQL keywords, table names, column names, and function names based on what it knows about your database. The autocomplete is context-aware. If you type a SELECT statement and then a FROM clause, the suggestions will show table names. If you continue to a WHERE clause, they switch to column names from the table you already chose. This reduces the need to memorize exact names or check a separate schema reference while writing queries. Beyond autocomplete, the tool colors SQL syntax to make queries easier to read, formats query results as clean tables with colors, and supports searching through previous queries using a fuzzy search tool. You can save frequently used queries under short aliases and call them back by name, optionally with parameters. Every query can optionally be logged to a file for later reference. The tool also supports SSL connections to databases, multiline queries, and the ability to pipe query output to other command-line tools using shell-style redirect operators. A recent addition lets you query language models using your database schema as context. Installation is available through pip on any platform, Homebrew on macOS, and the package managers of several Linux distributions including Debian, Ubuntu, Fedora, and Arch. It requires Python 3.10 or newer and is primarily tested on macOS and Linux. Windows is not officially supported but may work through the Windows Subsystem for Linux.
← dbcli on gitmyhub — every repo by this author, as a profile.
Verify against the repo before relying on details.