The legislation was approved by 299 lawmakers, while 19 voted against and 23 abstained.
The bill was backed by the majority-ruling Popular Party and the leading opposition Socialist Party, while some regional nationalist and left-wing parties rejected it or abstained.
Several left-wing deputies held up signs demanding a referendum on whether to scrap the monarchy.
The bill will now go to the Senate on Tuesday, with 46-year-old Felipe likely being proclaimed king two days later.
Juan Carlos earned wide respect for steering Spain's transition from dictatorship to democracy four decades ago, but recent scandals including going on a luxurious elephant-hunting safari as Spaniards struggled through an economic crisis have tarnished his image.
The 76-year-old monarch said he was stepping aside so that fresh royal blood could rally the nation.
The change comes as Spain limps out of a double-dip recession that has left some 6 million people unemployed.
It is also under political strain from growing drives for independence in northeastern Catalonia and the northern Basque region. Those challenges await Felipe.
The abdication announcement last week triggered widespread demonstrations calling for a referendum on reinstating a republic.
A recent poll found 62 per cent of respondents said they wanted a referendum on the monarchy "at some point."
Forty-nine per cent said they favoured a monarchy with Felipe as king, while 36 per cent wanted a republic. Others did not answer or expressed no opinion.
Juan Carlos became king in 1975, two days after the death of longtime dictator Gen Francisco Franco. He won massive support by staring down a 1981 coup attempt.
