Hi @Thejashwini L ,
Long processing of database queries is often the cause of slow pages loading. Often the reason for this is incorrectness of queries writing, lack of competent tables indexing, bulky and too complex requests and etc. Refer to this blog How To Make PHP Websites Run Faster?
Your issue is that your php, html page is loading too slow. Many factors will affect the load of php page. If SQL server query is not the root cause for your issue. We could not give you a better help. SQL server general tag that talking issues about SQL server Tech issues.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".