Home Tutorials Categories Skills About
ZH EN JA KO
🐬

MySQL

Database Database & Storage

Install Command

npx clawhub@latest install mysql

Installation Guide

1
Check Environment

Make sure Node.js 22+ and OpenClaw are installed. Run openclaw --version in your terminal to verify.

2
Run Installation

Run the install command above in your terminal. ClawHub will automatically download and install MySQL to the ~/.openclaw/skills/ directory.

3
Verify Installation

Run openclaw skills list to check your installed skills and confirm MySQL appears in the list.

4
Configure (Optional)

Follow the configuration instructions in the description below to add skill settings to ~/.config/openclaw/openclaw.json5.

Manual Installation: Copy the Skill folder to ~/.openclaw/skills/ or the skills/ directory in your project root. Make sure the folder contains a SKILL.md file.
SQL Queries Schema Analysis Data Export

Detailed Description

The MySQL skill lets OpenClaw connect directly to MySQL and MariaDB databases for data queries and management using natural language.

Core Features

  • Natural Language Queries: Describe query requirements in plain language with automatic MySQL SQL generation
  • Schema Browsing: View all tables, field definitions, and indexes in the database
  • Data Analysis: Execute aggregate queries and generate statistical reports
  • Slow Query Analysis: Identify performance bottlenecks with index optimization suggestions
  • Safe Mode: Read-only by default to prevent accidental modifications

Configuration

{
  skills: {
    mysql: {
      host: "localhost",
      port: 3306,
      database: "mydb",
      user: "readonly",
      password: "xxx",
      readOnly: true
    }
  }
}

Use Cases

  • "Query all orders from today in the orders table"
  • "What fields does the users table have?"
  • "Count new users added per month"
  • "Which queries are the slowest? What indexes need to be added?"

Security Recommendations

It is strongly recommended to use a read-only user when connecting to production databases to prevent the AI from executing write operations.