By David Alexander

WASHINGTON (Reuters) - The Republican-led House of Representatives voted on Friday to authorize $642.5 billion in defense spending next year, defying a White House veto threat by adding several billion dollars to President Barack Obama's Pentagon budget request.

The House approved the annual National Defense Authorization Act, which added nearly $4 billion to the president's spending plan, in a 299-120 vote just days after moving to shield the defense budget from further cuts by slashing social programs.

The vote on Friday sets up a confrontation over defense spending with the White House, which has warned of a presidential veto, and the Democratic-controlled Senate, which has yet to approve its version of the measure.

The authorization bill lets Congress set defense policy and authorize spending limits but it does not actually appropriate funds. The panel that actually controls the purse strings - the House Appropriations Committee - this week approved similar but slightly lower spending levels for defense.

The measure approved on Friday authorized a base defense budget of $554 billion, including Pentagon spending as well as nuclear defense activities of the Energy Department. The House authorized $88.5 billion for the Afghanistan war and other overseas operations.

The bill would delay or reverse many of the cuts sought by the Pentagon as part of efforts to reduce defense spending by $487 billion over the next decade. Congress ordered the spending cuts last year in an effort to rein in the government's trillion dollar deficits.

In addition to setting spending levels, the authorization bill reaffirmed the president's power to indefinitely detain suspected terrorists arrested in the United States and transfer them to military custody.

(Reporting By David Alexander; Editing by Bill Trott)