Impacts of working from Home country with valid H1 and payroll continue in the US

I’m on H1B visa and stamping is valid till 2025. Due to some family health situations I had to come back to India and will not be able to return to the US for an extended period. My client has agreed continue working for them remotely and my employer will continue running my payroll in the US.
Following are my questions related to visa and taxes

  1. Are there any legal complication from H1b standpoint?
  2. In which country I’m liable to pay taxes?
  3. Will there be any legal complication from Indian Tax Departments?
  4. What are the other items I need to be aware of?
  5. Upon my return, will there be any issues from USCIS/CBP?

Thank you very much

I am not sure how your employer agreed to run payroll while the H1B employee is not present in the US for an extended period.
It may be okay to run payroll for few weeks while H1B employee travel outside of the US for a short vacation however it may not be legal to keep running payroll when H1B employee is working from offshore for extended period. Your employer need to double check DOL rules specifically for H1B.
Normally, employers who have India presence will run payroll in India and pay the employee in Indian bank account if present in India for a long duration. This is the best approach for not violating any legal compliance.

You need to check substantial presence test for US and India. Generally speaking whichever country you stay for 180+ days, you will be considered tax resident for that country however you may have to file tax return in both countries and claim tax credits based on DTAA between the US and India. Consult a CA in India and a CPA in the US as tax filings can get complicated in your scenario.

None as far as you file your tax return and pay taxes correctly.

Work closely with your HR and immigration lawyer and make sure you carry required documents if the CBP officer asks for one.