Historians say Soviet leader Joseph Stalin created the famine, confiscating the harvest of Ukrainian peasants to force them to join collective farms.
The bill was proposed by President Viktor Yushchenko, who wants the UN to also recognise the famine as genocide.
Up to 10 million people died during the 1932-1933 famine.
MPs spent all day discussing two rival laws on the famine - the one put forward by the president and another proposed by the governing pro-Russian party which rejects the term genocide and instead refers to a "tragedy".
This is a symbolic victory for Mr Yushchenko, who demanded that MPs adopt his bill.
The pro-Western president no longer has a parliamentary majority but his former allies reunited to pass the law.
While this will strengthen Ukraine's bid to get the famine recognised by the UN as genocide, it will also anger Russia.
Moscow has already said the Soviet-era famine was not an attempt to wipe out the Ukrainian nation. This vote could now damage the country's fragile relations with Russia.
BBCGüncelleme Tarihi: 20 Eylül 2018, 18:16