Connect Erpnext database to php application

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

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…