The 27-year-old dominated from the start, flooring his opponent in the 10th round and winning 120-108, 119-108 and 117-110 on the judges' scorecards.
The belt could only be won by Yafai after the Panamanian was stripped of it when he failed to make the weight.
Unbeaten in 21 professional fights, Yafai previously held the Commonwealth and British super-flyweight belts.
The Birmingham fighter also won a silver medal at the 2010 European Championships during his amateur career.
"It's unbelievable, it's going to take a while to sink in," he said. "I knew I was going to do it, it was just a matter of how. I just did what I needed to do.
"I can't wait to headline in Birmingham as a world champion. My hands are a bit sore so I might be out for a little bit, but the second I can get in the gym I will be back working and getting ready to defend this belt."
The fight was part of a packed undercard as Britain's Anthony Joshua retained his IBF world heavyweight championship by knocking out American Eric Molina.
Bury's Scott Quigg won his first fight since losing to Carl Frampton in February, and his first as a featherweight, outpointing Mexico's Jose Cayetano.
Former super-bantamweight world champion Quigg, 28, had his jaw broken by Frampton but showed no signs of frailty on his return to the ring.
Cayetano, himself fighting at 126lb for the first time, was unmoved by most of his opponent's punches until the end of the eighth round, when he began to wilt.
And Quigg finished his rival off with a flashing left-right combination at close quarters, the referee calling a halt to proceedings with Cayetano on the deck.
Quigg has plenty of options at featherweight. Frampton moved up and claimed the WBA featherweight title in July, Welshman Lee Selby is the IBF title-holder and Leeds' Josh Warrington is also in the hunt for a world title.
Liverpool's Callum Smith stayed on course for a world title shot with a brutal 10th-round knockout of game Lancastrian Luke Blackledge.
Referee Steve Gray could have stopped the fight earlier but allowed the one-sided battering to continue until Blackledge was knocked unconscious.
There were an anxious few minutes as a prone Blackledge was administered oxygen before he gingerly, and mercifully, made it back to his feet.
Smith, 26, successfully defended his British title for the first time and remained unbeaten in 22 pro fights, with 17 knockouts.
He is ranked number one by the WBC but Sweden's Badou Jack is defending that belt against Britain's IBF champion James DeGale in January.
In a thrilling light-heavyweight contest, Frank Buglioni stopped Hosea Burton in the 12th and final round to secure the British title.
Manchester's Burton, 28, built an early lead behind his jab and some ramrod right hands, and the challenger's face was a bloody mess by the middle rounds.
However, the Londoner's punches started to have an effect down the stretch and Burton went down under a barrage in the 11th.
Midway through the 12th, Burton was stunned by a right to the temple before going down again. He clambered to his feet but the referee called things off after another assault by Buglioni, with a minute and four seconds remaining.
Buglioni, 27, improves to 19 wins (15 KOs) and two defeats from 22 pro fights and could be rewarded with a second shot at a world title.
Welterweight Conor Benn, son of British legend Nigel, made it six wins out of six with a first-round knockout of Manchester's Steven Backhouse.
Find out how to get into boxing with our special guide.
Britain's Kal Yafai won the WBA super-flyweight title with a unanimous decision over Luis Concepcion.