The House yesterday approved the first authorization bill for housing programs since 1980, voting 391 to 1 to provide $30.6 billion over the next two years for major housing and community development.

The compromise bill, worked out in a conference committee between House and Senate negotiators, provides $15 billion for the fiscal year that ends Sept. 30, 1988, and $15.64 billion for fiscal 1989. The Reagan administration opposes the $15 billion yearly level for housing and is threatening a veto if the final legislation contains those amounts.

The compromise measure, which still must be approved by the Senate, is about $900 million below a House-passed bill and more than $600 million below the Senate-passed bill. Rep. Philip M. Crane (R-Ill.) cast the only opposing vote.

President Reagan's budget request for the Department of Housing and Urban Development for fiscal 1988 was $10.2 billion.

The funding level in the bill is less than either the $15.9 billion in the House-passed measure or the $15.6 billion envisioned by the Senate.

The bill would hold spending for most housing and development activities at current levels. It would provide $3 billion for Community Development Action Grants and $225 million for Urban Development Action Grants.

Low- and moderate-income families who are displaced when their homes are demolished or converted to other uses because of development funded by the two federal programs would be given other affordable housing for 10 years, as well as money for moving expenses.

More than 900,000 units in privately owned buildings are in danger of being lost to the low-income housing stock over the next decade as regulatory restraints that ensure their use as low- and moderate-income housing expire, according to supporters of the measure.

The conference agreement authorizes $9.2 billion in fiscal 1988 and $9.7 billion in fiscal 1989 for assisted housing programs, including low-income assistance, elderly and handicapped housing, new public housing and grants for public housing improvement assistance programs. The House version provided $10 billion for such programs in fiscal 1988 only.

The Federal Housing Administration's home mortgage insurance program would be permanently reauthorized, and a $100 billion limit would be set on mortgages the FHA can insure next year. Congress hopes to avert future shutdowns of the FHA insurance program.