Rebel members of President Donald Trump's party have helped pass a vote to reject his declaration of an emergency on the US-Mexico border.
Twelve Republican senators broke party ranks to side with Democrats, approving a proposal to revoke the proclamation by 59-41.
The Democratic-controlled House of Representatives last month backed the measure.
Following Thursday's vote, Mr Trump tweeted: "VETO!"
Congress needs a two-thirds majority of both chambers to override a presidential veto, which is viewed as unlikely in this case.
Nevertheless, the vote will be seen as an embarrassing loss for the president on his signature domestic issue.
On Twitter, Mr Trump slammed the vote, calling it a "Democrat inspired Resolution which would OPEN BORDERS while increasing Crime, Drugs and Trafficking in our Country".
It comes just a day after the Senate rebuked him on foreign policy by approving a bill to end US support for the Saudi-led coalition in Yemen.
The Republican rebels on Thursday were Mitt Romney and Mike Lee of Utah, Marco Rubio of Florida, Roy Blunt of Missouri, Lamar Alexander of Tennessee, Pat Toomey of Pennsylvania, Rob Portman of Ohio, Jerry Moran of Kansas, Susan Collins of Maine, Lisa Murkowski of Alaska, Rand Paul of Kentucky, and Roger Wicker of Mississippi.
Thom Tillis of North Carolina changed his mind minutes before the vote and said he would oppose it.
The Republican president declared the emergency on 15 February after Congress refused funding for a wall on the US-Mexico border, a key campaign pledge.
He aims to circumvent Congress and build his long-promised barrier by raiding military budgets.
It could free up almost $8bn (£6bn) for the wall, which is still considerably short of the estimated $23bn cost of a barrier along almost 2,000 miles (3,200km) of border, but far more than the nearly $1.4bn begrudgingly allotted last month by Congress.
Have your say
More World Headlines
- Alabama sued over 'extreme' abortion ban
- Kenya upholds law criminalising gay sex
- Watch Obama play baseball, football with kids in D.C
- Theresa May announces resignation
- Rockets 'hit luxury hotel in Libya's capital'
- US lays new charges against Assange
- Nigeria: Six trapped in collapsed building
- UN backs end to UK control of Chagos islands
- Armed gang kills at least 18 in northwest Nigeria
- Female BBC manager rejects job over equal pay
- U.S. House's Pelosi: Trump is engaged in 'cover-up'
- Uber driver was Somali war criminal
- A baby cut from his mother's womb after she was killed opens his eyes
- South Sudanese journo beats Dangote in Fortune magazine’s World’s Greatest Leaders list
- Vibrator prize for Spanish squash champion spurs sexism debate