# Can't find my.ini in MySQL directory?

MySQLMySQLi Database

The my.ini is in hidden folder of program data. First go to C: drive and then hidden folder of program data. From that, move to the MySQL version directory.

Here is the snapshot of the C: drive −

Click on C drive. The snapshot is as follows. Here, you can see the Program Data folder −

Now go to MySQL under Program Data folder. The snapshot is as follows −

Go to MySQL version. The snapshot is as follows −

Note − Here, we are using MySQL version 8.0.12

Here is the my.ini file.

In order to reach the location, you can also use the following command −

mysql> select @@datadir;

The following is the output −

+---------------------------------------------+
1 row in set (0.00 sec)