Skip to main content

Neo4j CLI

Project description

Neo4j CLI

Installation

Prebuilt archives (recommended)

Download the archive for your OS/arch from the releases page and extract the neo4j-cli binary.

npm

npm i -g @neo4j-labs/cli

Installs a small Node wrapper plus a prebuilt neo4j-cli binary matching your OS and CPU. pnpm add -g @neo4j-labs/cli and yarn global add @neo4j-labs/cli work the same way. Prereleases via npm i -g @neo4j-labs/cli@alpha (also @beta, @rc, @next). See distribution/npm/cli/README.md for the supported platform matrix.

Note: To install a pre-release, the version must be specified for pip, pipx etc.. This is achieved by adding == immediately after neo4j-cli with the version you want. For example, pipx install neo4j-cli==0.1.0a6 will install 0.1.0a6 of Neo4j CLI

pip

pip install neo4j-cli

pipx

pipx install neo4j-cli

uv

uv tool install neo4j-cli

uvx

uvx will install and execute neo4j-cli. This means that you must include the commands you want to use with uvx

uvx -i neo4j-cli YOUR_COMMANDS

Check the installation by running neo4j-cli --help

Usage

Extract the executable to a directory of your choosing.

Create Aura API Credentials in your Account Settings, and note down the client ID and secret.

Add these credentials into the CLI with a name of your choosing:

./neo4j-cli aura credential add --name "Aura API Credentials" --client-id <client-id> --client-secret <client-secret>

This will add and set the credential as the default credential for use.

You can then, for example, list your instances in a table format:

./neo4j-cli aura instance list --format table

If you would rather just type neo4j-cli then move the neo4j-cli binary into the file path of your computer.
Windows:

move neo4j-cli.exe c:\windows\system32

Mac:

sudo mv neo4j-cli /usr/local/bin

To see all of the available commands:

./neo4j-cli

Help for each command is accessed by using it without any flags or options. For example, to see help creating an instance:

./neo4j-cli aura instance create

Querying Neo4j

neo4j-cli query runs Cypher against any Neo4j database via the Bolt protocol. Cypher comes from the positional argument or piped stdin.

./neo4j-cli query 'RETURN 1 AS n'
echo 'MATCH (n) RETURN count(n)' | ./neo4j-cli query

Connection settings are resolved with this precedence (highest first): flag → env var → .env file (auto-discovered by walking up from cwd) → built-in default.

Setting Flag Env var Default
URI --uri NEO4J_URI neo4j://localhost:7687
Username --username NEO4J_USERNAME neo4j
Password --password NEO4J_PASSWORD prompted on TTY
Database --database NEO4J_DATABASE neo4j

http:// and https:// URIs are auto-rewritten to neo4j://<host>:7687 and neo4j+s://<host>:7687 respectively (path/query stripped). For self-signed certs use neo4j+ssc://.

Pass parameters with --param key=value (repeatable). Values that parse as JSON are typed; everything else is a string:

./neo4j-cli query 'MATCH (p:Person {name:$name}) RETURN p' --param name=Alice
./neo4j-cli query 'RETURN $ids' --param 'ids=[1,2,3]'
echo 'MATCH (p:Person {name:$name}) RETURN p' | ./neo4j-cli query --param name=Alice

Output is a table by default; pass --format json for a stable envelope (columns, rows, truncated, arrays_truncated). When stdout is not a terminal (piped or redirected), --format defaults to json. Applies to both query and :schema. Large results are capped at 100 rows and arrays inside cells at 100 items — tune with --max-rows / --truncate-arrays-over (0 = unlimited).

Schema introspection:

./neo4j-cli query :schema

Write operations

Write commands require --rw. neo4j-cli query runs EXPLAIN first when --rw is absent and blocks mutating Cypher before execution.

./neo4j-cli aura instance delete <id> --rw
./neo4j-cli config set telemetry false --rw
./neo4j-cli query 'CREATE (:Person {name:"Alice"})' --rw

Agent skills

neo4j-cli ships an embedded skill bundle (SKILL.md + per-subcommand references) that teaches AI coding agents how to drive the CLI. skill install drops that bundle into the supported agents' skill directories so the agent picks it up on next run.

Supported agents:

  • Claude Code
  • Cursor
  • Windsurf
  • Copilot
  • Gemini CLI
  • Cline
  • Codex
  • Pi
  • OpenCode
  • Junie

Install into every detected agent (or pass an agent name to target one):

./neo4j-cli skill install
./neo4j-cli skill install claude-code

List supported agents and per-agent install state:

./neo4j-cli skill list

Check installed bundles for version drift against the running binary:

./neo4j-cli skill check

Remove the installed bundle (idempotent):

./neo4j-cli skill remove
./neo4j-cli skill remove claude-code

Beta features (commands gated by AuraBetaEnabled, e.g. dataapi, import, deployment) are not included in the generated bundle — the bundle reflects the default-config command surface.

Feedback / Issues

Please use GitHub issues to provide feedback and report any issues that you have encountered.

Building locally

Clone the repository and run:

make build

This produces bin/neo4j-cli. To run without building:

make run-neo4j

Developing and contributing

Read CONTRIBUTING.md

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

neo4j_cli-0.1.0a8-py3-none-win_arm64.whl (13.3 MB view details)

Uploaded Python 3Windows ARM64

neo4j_cli-0.1.0a8-py3-none-win_amd64.whl (14.5 MB view details)

Uploaded Python 3Windows x86-64

neo4j_cli-0.1.0a8-py3-none-manylinux_2_17_x86_64.whl (14.1 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ x86-64

neo4j_cli-0.1.0a8-py3-none-manylinux_2_17_aarch64.whl (13.1 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ ARM64

neo4j_cli-0.1.0a8-py3-none-macosx_11_0_arm64.whl (13.7 MB view details)

Uploaded Python 3macOS 11.0+ ARM64

neo4j_cli-0.1.0a8-py3-none-macosx_10_9_x86_64.whl (14.6 MB view details)

Uploaded Python 3macOS 10.9+ x86-64

File details

Details for the file neo4j_cli-0.1.0a8-py3-none-win_arm64.whl.

File metadata

  • Download URL: neo4j_cli-0.1.0a8-py3-none-win_arm64.whl
  • Upload date:
  • Size: 13.3 MB
  • Tags: Python 3, Windows ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for neo4j_cli-0.1.0a8-py3-none-win_arm64.whl
Algorithm Hash digest
SHA256 fa5640b405b207b364faa1b4825d163878eef0f5ab87ab4b849861688bfa894c
MD5 ae2b47b0bec0e6b182370dd5d852c490
BLAKE2b-256 12bce0ebbeda3a05d46f11ef6ddd602e26be81e64188972c8a05aef97acf842f

See more details on using hashes here.

File details

Details for the file neo4j_cli-0.1.0a8-py3-none-win_amd64.whl.

File metadata

  • Download URL: neo4j_cli-0.1.0a8-py3-none-win_amd64.whl
  • Upload date:
  • Size: 14.5 MB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for neo4j_cli-0.1.0a8-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 8c02fb4e97eb94ba765ae81af5d4f06de78c519116330fc75ae1d89172ac355e
MD5 96fceec66d7bf37e34ceb54201200c9c
BLAKE2b-256 56936d69304c01e883bd3c6c112e3dc4f93fd70ad59f0277e0900f97b88a340d

See more details on using hashes here.

File details

Details for the file neo4j_cli-0.1.0a8-py3-none-manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for neo4j_cli-0.1.0a8-py3-none-manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 0acbf54056f436ad59783a1eea817eae1e71f4566d2584fce9ea8d00b9c7983c
MD5 c2f98f873ee3aa186086f97ed9607597
BLAKE2b-256 421ef5841f72bdf658ecbd19f598c29de6cf768516cf30f0d3b38183835dbc98

See more details on using hashes here.

File details

Details for the file neo4j_cli-0.1.0a8-py3-none-manylinux_2_17_aarch64.whl.

File metadata

File hashes

Hashes for neo4j_cli-0.1.0a8-py3-none-manylinux_2_17_aarch64.whl
Algorithm Hash digest
SHA256 ffbbf557ffa8e69e1b1b99c02a395020e219d27602ec0b26f96092f40cb832f4
MD5 9eff22c2b08705b0196e4482da7fa8fe
BLAKE2b-256 7042871bdebd273959d8fad8b616a5a938cc8f38522a5049e3c3b88c51f3e9e8

See more details on using hashes here.

File details

Details for the file neo4j_cli-0.1.0a8-py3-none-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for neo4j_cli-0.1.0a8-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 247b9a9d7718b95009f04e6a430c3a9b2a8663d079342462a1a08fb8245a9723
MD5 4919f1e601c9e4961c18fdfae5cbb190
BLAKE2b-256 0006969b674e199ff5f0e88e2b8e6e46a486fd0f56d1a07b15c477227af8d65c

See more details on using hashes here.

File details

Details for the file neo4j_cli-0.1.0a8-py3-none-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for neo4j_cli-0.1.0a8-py3-none-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 ab8d543b6575e36ab8ce19f577fbaa06d8d7187144490f523459e4c0cdd74a69
MD5 56ef226bf870f3ee10f40bcc3c0af665
BLAKE2b-256 2518491c18af3e518a9de8b5684aacc63719ce5bb49db65626e82c26254f1920

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page