{"id":16117,"library":"mcp-server-sqlite-npx","title":"MCP SQLite Server (npx)","description":"This package provides a Node.js implementation of the Model Context Protocol (MCP) SQLite server, currently at version `0.8.0`. It serves as an npx-based alternative to the official Python reference implementation, specifically designed for environments where the Python UVX runner is unavailable or impractical, such as certain Node.js-centric applications like LibreChat. The server allows applications to interact with an SQLite database via the MCP protocol. Its release cadence appears to be driven by feature development and integration needs, rather than a fixed schedule. A key differentiator is its enablement of MCP SQLite functionality within Node.js ecosystems without requiring Python installations, making it suitable for environments where only Node.js is readily available.","status":"active","version":"0.8.0","language":"javascript","source_language":"en","source_url":null,"tags":["javascript"],"install":[{"cmd":"npm install mcp-server-sqlite-npx","lang":"bash","label":"npm"},{"cmd":"yarn add mcp-server-sqlite-npx","lang":"bash","label":"yarn"},{"cmd":"pnpm add mcp-server-sqlite-npx","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"This is the primary method to run the server as a temporary executable, leveraging npm's `npx` runner without global installation. The `-y` flag bypasses confirmation prompts.","symbol":"npx mcp-server-sqlite-npx","correct":"npx -y mcp-server-sqlite-npx /absolute/path/to/database.db"},{"note":"Used for local development and testing after building the TypeScript source (e.g., `npm run build`), running the compiled server directly with Node.js. This method requires the repository to be cloned and built.","symbol":"node dist/index.js","correct":"node /absolute/path/to/dist/index.js /absolute/path/to/database.db"},{"note":"This represents how client applications (e.g., Claude Desktop) 'import' or integrate the server by specifying its execution command and arguments within their JSON configuration files, rather than through direct JavaScript module imports. Absolute paths are critical for reliability.","symbol":"mcpServers.sqlite configuration","correct":"{ \"mcpServers\": { \"sqlite\": { \"command\": \"/absolute/path/to/npx\", \"args\": [\"-y\", \"mcp-server-sqlite-npx\", \"/absolute/path/to/database.db\"], \"env\": { \"PATH\": \"...\", \"NODE_PATH\": \"...\" } } } }"}],"quickstart":{"code":"// First, ensure you have Node.js and npm/npx installed.\n// Create a SQLite database file, e.g., 'my_database.db', or use an existing one.\n// Replace '/absolute/path/to/my_database.db' with your actual database file path.\n\n// To test the server using the MCP Inspector tool, run the following command in your terminal:\n// This command will install the inspector temporarily via npx, then use it to launch\n// and connect to the mcp-server-sqlite-npx instance.\n\n// If you have cloned the mcp-server-sqlite-npx repository and built it (npm ci && npm run build):\n// npx @modelcontextprotocol/inspector node dist/index.js /absolute/path/to/my_database.db\n\n// If you are using the published npm package directly, and assuming mcp-server-sqlite-npx\n// is in your node_modules (e.g. from a prior `npm i mcp-server-sqlite-npx` or `npx ...` call):\nconsole.log(\"Starting MCP SQLite server via npx and connecting with Inspector...\");\nconsole.log(\"Run this command in your terminal:\");\nconsole.log(\"\\nnpx @modelcontextprotocol/inspector npx mcp-server-sqlite-npx /absolute/path/to/my_database.db\\n\");\nconsole.log(\"Replace '/absolute/path/to/my_database.db' with the actual path to your SQLite file.\");\nconsole.log(\"After launching, connect and go to the 'Tools' tab in the Inspector to interact with the server.\");","lang":"typescript","description":"Demonstrates how to run the `mcp-server-sqlite-npx` server using the `npx @modelcontextprotocol/inspector` tool for local testing and interaction via its CLI interface."},"warnings":[{"fix":"Always use full, absolute file system paths for `command` (e.g., `/Users/user/.nvm/.../npx`), the database file argument (e.g., `/Users/user/projects/database.db`), and any paths specified within `env` variables like `PATH` or `NODE_PATH`. Be mindful of platform-specific path separators (e.g., `\\` on Windows).","message":"When configuring `mcp-server-sqlite-npx` for clients like Claude Desktop, absolute paths are generally required for the `command`, `args`, and `env` variables. Relative paths may lead to execution failures or environment variable issues, especially across different user contexts or operating systems.","severity":"gotcha","affected_versions":">=0.1.0"},{"fix":"Interact with the `mcp-server-sqlite-npx` via its Model Context Protocol API as a separate process, typically launched through `npx` or configured in client applications (like Claude Desktop) to run as an external command. Treat it as an external service rather than an in-process module.","message":"The `mcp-server-sqlite-npx` package is primarily an executable server, not a library designed for programmatic import into other JavaScript or TypeScript applications. Attempting to `import` or `require` its internal modules for direct use may lead to unexpected behavior, API instability, or lack of defined exports.","severity":"gotcha","affected_versions":">=0.1.0"},{"fix":"Ensure `NODE_PATH` points to the `node_modules` directory of the Node.js installation being used (e.g., `/Users/{username}/.nvm/versions/node/vX.Y.Z/lib/node_modules`). Similarly, `PATH` must include the directory containing the `node` and `npx` binaries (e.g., `/Users/{username}/.nvm/versions/node/vX.Y.Z/bin`). Use absolute paths and correctly handle platform-specific environment variable expansion (e.g., `%PATH%` on Windows).","message":"Incorrect configuration of `NODE_PATH` or `PATH` within the `env` section of `claude_desktop_config.json` can prevent `npx` or `node` from finding required executables or modules, especially when using Node.js version managers (like NVM) or custom installations.","severity":"gotcha","affected_versions":">=0.1.0"}],"env_vars":null,"last_verified":"2026-04-21T00:00:00.000Z","next_check":"2026-07-20T00:00:00.000Z","problems":[{"fix":"Install Node.js (which bundles npm and npx) from the official Node.js website. Verify that the Node.js installation directory is correctly added to your system's PATH environment variable.","cause":"Node.js and its accompanying package runner, npx, are not installed or are not accessible in the system's PATH.","error":"npx: command not found"},{"fix":"Verify the absolute path to your SQLite database file. Ensure the file exists, or create an empty `.db` file if it's new. Check that the user account running the `mcp-server-sqlite-npx` process has read and write permissions to the database file and its parent directory.","cause":"The specified SQLite database file path provided as an argument to the server does not exist or the process lacks the necessary permissions to access it.","error":"Error: ENOENT: no such file or directory, open '/absolute/path/to/database.db'"},{"fix":"Double-check the absolute path to your `npx` or `node` executable (e.g., `/Users/{username}/.nvm/versions/node/vX.Y.Z/bin/npx` on macOS/Linux, or `C:\\Program Files\\nodejs\\npx.cmd` on Windows). Ensure the path is correct and accessible by the client application.","cause":"The `command` path specified in a client's configuration (e.g., `claude_desktop_config.json`) for `npx` or `node` is incorrect, not absolute, or the specified executable is missing, preventing the client from successfully launching the server process.","error":"Failed to launch server: command '...' not found (when configured in client application)"}],"ecosystem":"npm"}