- Navigate to phpMyAdmin by URL http://your_ip/phpmyadmin or http://localhost/phpmyadmin
- Login using username root and root password.
- Click on Databases tab.
- Enter database name, select collation (you may leave it to default) and click create.
- Click on Privileges tab and select "Add user account".
- You can select localhost if the connection is made only form local. Select "any host" if you are planing to connect from different hosts.
- Enter new username and password.
- Select the privileges you need for that user.
- Click on Database tab and select the database for which you need to give access(in our case the newly created database in step 4). Click Go.
if you want to reproduce, please indicate the source:
Getting started with phpmyadmin – How to create a database and grant privileges for database user. - CodeDay