How to Fix MariaDB Error HY000/1130: Host ‘localhost’ Not Allowed to Connect in XAMPP

How to Fix MariaDB Error HY000/1130: Host ‘localhost’ Not Allowed to Connect in XAMPP

XAMPP MariaDB error fix. Web applications commonly use MariaDB, which is an open-source relational database management system. If you’re developing a web application locally using XAMPP, you may encounter an error message that says

mysqli::real_connect(): (HY000/1130): Host 'localhost' is not allowed to connect to this MariaDB server

Several factors can cause this error, such as incorrect username or password, host-based authentication, or network issues. In this article, we’ll show you how to fix this MariaDB error in XAMPP.

mysqli::real_connect(): (HY000/1130): Host ‘localhost’ is not allowed to connect to this MariaDB server

mysqli::real_connect(): (HY000/1130): Host 'localhost' is not allowed to connect to this MariaDB server
XAMPP MariaDB error fix

Solving MariaDB Error HY000/1130: Host ‘localhost’ Not Allowed to Connect

Troubleshooting MariaDB Error 1130: Host ‘localhost’ Access Denied

Fixing MySQLi Error HY000/1130: Host ‘localhost’ Not Authorized to Connect

Step-by-Step Guide to Resolving MariaDB Error HY000/1130

So now how to Resolving MariaDB issue in XAMPP

Step 1: Open XAMPP Control Panel

xampp control panel
XAMPP MariaDB error fix

First, open XAMPP Control Panel. You can do this by clicking on the XAMPP icon in your taskbar or by searching for “XAMPP Control Panel” in your Start menu.

Step 2: Open my.ini File

mysqli config file

Next, click on the “Config” button for the MySQL module. This will open the mysqli configuration file in your default text editor.

Step 3: Add skip-grant-tables

xampp mysqli config my.ini fille
XAMPP MariaDB error fix

In the my.ini file, find the section that begins with “# The MySQL server“. Under this section, add a new line that says “skip-grant-tables” after the “[mysqld]” line.

WiFi not working in Kali Linux 2020.4 [Fix ]

incase you missed

Step 4: Save and Close my.ini File

Save the my.ini file and close the text editor.

If you facing any issue with saving my.ini file then click on “File” and then select “Save As“. Save the file as “my.ini” in the “xampp/mysql/bin” directory.

Step 5: Restart Apache and MySQL

Finally, restart both the Apache and MySQL modules in XAMPP Control Panel. You can do this by clicking on the “Stop” button for each module and then clicking on the “Start” button again.

in case you miss
Android Hacking: Exploit ADB using Ghost Framework in Kali Linux

That’s it! You should now be able to connect to your MariaDB server without encountering the “Host ‘localhost’ is not allowed to connect” error.

Conclusion

MariaDB error HY000/1130: Host ‘localhost’ not allowed to connect can be a frustrating issue to deal with when developing web applications using XAMPP. Fortunately, by following the steps outlined in this article, you can fix this error and get back to developing your web application.

Facebookhttps://www.facebook.com/pastfutur.official
Instagram: https://www.instagram.com/pastfutur.official/
Telegramhttps://t.me/pastfutur_official

Don’t forget to follow us

About Fattain Naime

Hi, my name is Fattain Naime and I am a computer engineer and young entrepreneur. After graduating, I decided to follow my passion and start my own company, Builder Hall Pvt. Ltd. I am dedicated to using my technical skills and entrepreneurial spirit to create innovative solutions for my clients.Throughout my academic and professional career, I have developed a strong foundation in computer engineering principles, including programming languages, data structures, and algorithms. I have also gained experience in project management and business development, which has allowed me to successfully lead my own company.Since founding Builder Hall, I have worked tirelessly to build a team of talented professionals and bring cutting-edge technology solutions to the market. Our focus is on providing our clients with the best possible experience and helping them to achieve their business goals through the use of technology.In my role as CEO, I have been responsible for leading the company's strategy and overseeing all aspects of operations. I am constantly seeking out new opportunities for growth and expansion, and I am committed to building a culture of excellence within the company.Outside of work, I am an avid reader and enjoy staying up-to-date on the latest developments in the tech industry. I also enjoy spending time with my family and staying active through sports and fitness activities.If you're looking for a dynamic, driven computer engineer with a passion for entrepreneurship, don't hesitate to reach out and connect with me on LinkedIn. I'm always open to discussing new opportunities and ideas. Make the world easier.I am excited to share my skills and experience with others, and I hope to connect with like-minded individuals who are passionate about technology and entrepreneurship. Thank you for visiting my profile.

View all posts by Fattain Naime →

Leave a Reply

Your email address will not be published. Required fields are marked *