“We look forward to a swift approval by the Senate and the governor’s signature, as this is a critical element of the foster care system reform,” said Jennifer Carr Allmon, the group’s executive director.

If the bill becomes law, the state would be forbidden from penalizing an agency — declining to renew a contract or license, for example — that cited religious objections when denying service to someone. Advocacy groups said it might affect a wide range of prospective parents, including non-Christians, people in interfaith marriages or those who have been divorced and remarried.

A similarly far-reaching bill was signed into law in March in South Dakota. And just six days before the Texas bill was approved by the House, a similar but more narrowly focused bill that did not cover publicly funded agencies was signed into law in Alabama.

Texas is grappling with a long-running crisis in its Child Protective Services division, which a federal judge ruled in 2015 had violated the constitutional rights of children under its care by exposing them to an unreasonable risk of harm. The bill’s author, Representative James Frank, said in a statement that it would help address the crisis by ensuring that faith-based adoption agencies are free to do their work without fear of litigation.

“At a time when we need all hands on deck, we face the real risk of seeing a large number of these providers leave the field, as they are forced to make the choice between devoting a substantial amount of resources in fighting litigation and other adverse action, or using those resources on other services to fulfill the tenets of their faith,” the statement said.