The U.S. government considers the Chinese companies a security risk and has pushed its allies not to use Huawei equipment in next-generation cellular networks, known as 5G.
Both companies have denied that China uses their products for spying.
The Federal Communications Commission has already voted to bar U.S. phone companies from using government subsidies for equipment from the two Chinese companies. This affects mostly small, rural companies, because the major U.S. network providers don't use the Chinese equipment.
The small phone companies have complained that it will be difficult and expensive for them to rebuild their networks.
Their trade group has said that it would cost up to $1 billion for its dozen member companies to replace Huawei and ZTE equipment, and it has said that Huawei has 40 customers in the U.S. The group, Rural Wireless Association, applauded passage of the bill Thursday.
The bill would reimburse telecom providers with fewer than 2 million customers.
Huawei and ZTE did not immediately reply to requests for comment.