Pakatan Harapan will be able to form the federal government after winning the 14th General Election (GE14) with a simple majority of 113 out of 222 seats
The announcement on the tally was made by the Election Commission (EC) at 4.55am.
The victory ensures that the coalition forms the federal government, ending Barisan Nasional's unbroken 61-year rule.
The Barisan Nasional coalition won 133 seats in parliament during the 13th General Election that was held in 2013.
The PH coalition announced earlier this year that Tun Dr Mahathir Mohamad is their prime ministerial candidate of choice while Dr. Wan Azizah Wan Ismail will be Mahathir's deputy if PH wins GE14
However, Mahathir would have to vacate the post to make way for jailed leader Datuk Seri Anwar Ibrahim once he is eligible to be appointed for the post.
The EC had announced earlier that the following parties are able to form the state governments after obtaining a simple majority
Johor - PH (29 out of 56 seats)
Kedah - PH (18 out of 36 seats); PAS (15 seats); BN (3 seats)
Kelantan - PAS (28 out of 45 seats)
Melaka - PH (15 out of 28 seats)
Negeri Sembilan - PH (20 out of 36 seats)
Pahang - BN (22 out of 42 seats)
Perak - PH (29 out of 59 seats); BN (27 seats); PAS (3 seats)
Perlis - BN (10 out of 15 seats)
Penang - PH (25 out ot 40 seats)
Sabah - BN (29 out of 60 seats); Warisan (29 seats)
Selangor - PH (29 seats out of 56 seats)
Terengganu - PAS (18 out of 32 seats)
Meanwhile, Pakatan Harapan clinched 11 seats in the Federal Territories in GE14
Barisan Nasional retained its two seats in Putrajaya and Labuan as Pakatan Harapan went on to win 11 other seats namely: Bandar Tun Razak, Kepong, Cheras, Bukit Bintang, Seputeh, Lembah Pantai, Segambut, Batu, Titiwangsa, Setiawangsa and Wangsa Maju.
GE14 has been a momentous occasion. Take a look back at how Malaysian voters went through polling day here: