Connect Erpnext database to php application

Hi
I want to access database mysql of erpnext. I want to connect that database into my php code.
I want to fetch data from erpnext , and wants to show that data into new php project.

This is the API doc

https://frappe.io/docs/user/en/guides/integration/rest_api

You probably don’t need to access mysql DB directly. But if you really have to, the DB configs are under sites/[Site-Name]/site_config.json

1 Like

I strongly suggest to use Rest API and don’t connect directly…