Skip to main content
SQL Developer — help/connect-mysql.md
port 3306 · JDBC

How to Connect SQL Developer to MySQL

Connect to your MySQL database in under 5 minutes. This guide covers JDBC driver setup, connection configuration, and common troubleshooting tips.

~/connections/mysql.spec setup overview

# Connection target

database = MySQL 5.7+ / 8.x / MariaDB-compatible

driver = MySQL Connector/J (JDBC)

port = 3306 # default; configurable

protocol = TCP # SSL/TLS optional

auth = username/password

# Setup info

time = 5 minutes

difficulty = Beginner

steps = 6

prereq = SQL Developer installed + MySQL JDBC .jar

// 6 setup steps + connection examples + troubleshooting below

Before You Start

What you'll need before opening the New Connection dialog.

  • SQL Developer installed — download free if you haven't yet
  • MySQL server running and reachable from your machine
  • MySQL credentials: hostname, port, username, password, and the database name
  • MySQL JDBC Driver (Connector/J) — Step 1 below shows you how to get it

Connect to MySQL Step by Step

Follow these six steps to set up your MySQL connection. Total time: about 5 minutes.

STEP_01

Get the MySQL JDBC Driver

Download MySQL Connector/J from the official MySQL website. Choose the "Platform Independent" ZIP file. Extract it and note the location of the mysql-connector-j-x.x.x.jar file.

STEP_02

Add Driver to SQL Developer

In SQL Developer, go to Tools → Preferences → Database → Third Party JDBC Drivers. Click Add Entry and select the .jar file from Step 1.

STEP_03

Create New Connection

Click the green + icon in the Connections panel. In the dialog that opens, click the MySQL tab on the left side.

STEP_04

Enter Your Details

Connection Name: any name you want
Username: your MySQL user
Password: your MySQL password
Hostname: localhost or server IP
Port: 3306 (default)
Database: your database name

STEP_05

Test Connection

Click Test to verify everything works. You should see Status: Success. If not, check the error message and see the troubleshooting section below.

STEP_06

Save and Connect

Click Save to keep the connection for future use, then click Connect. Your MySQL database is now ready to use.

MySQL Connection Details

Three common configurations — local server, remote host, and Amazon RDS — shown as connection config blocks.

~/connections/local.conflocal MySQL

# Local MySQL Server (most common dev setup)

hostname = localhost

port = 3306

database = your_database_name

~/connections/remote.confremote MySQL

# Remote MySQL Server (production or shared dev host)

hostname = your-server.com # or IP address

port = 3306 # or custom port

database = your_database_name

~/connections/aws-rds.confAmazon RDS MySQL

# Amazon RDS endpoint (with region in hostname)

hostname = your-instance.xxxx.region.rds.amazonaws.com

port = 3306

database = your_database_name

Common MySQL Connection Errors

Quick fixes for the three problems most often hit during MySQL setup.

~/downloads ready.sh

Next: Connect to Another Database?

SQL Developer connects to PostgreSQL, Oracle, SQL Server, SQLite, and MariaDB with the same New Connection dialog flow — the setup steps are nearly identical to MySQL, only the JDBC driver and port number change.

// next.specconnect-postgresql.md · port 5432
// see-alsogetting-started.md · keyboard-shortcuts.md