Lil Wayne was released from the Rikers Island jail complex, according to the New York Department of Correction website.
The Grammy Award-winning star pleaded guilty in October 2009 after a semi-automatic pistol was found on his tour bus.
"FREE AT LAST!!!!!!!" the rapper's longtime manager, Cortez Bryant, Tweeted Thursday morning.
According to his managers, Lil Wayne is headed to his home in Miami, where a welcome-home party is planned for Sunday.
Mack Maine, a childhood friend of the rapper and the president of the his record label Young Money Entertainment, told MTV News that after the party, Lil Wayne and his friends will go to a strip club.
Lil Wayne, who had the best-selling album of 2008 and won a best rap album Grammy with "Tha Carter III," kept his career in high gear while he was in jail.
His latest album, "I Am Not a Human Being" - released while he was in solitary confinement in September - hit No. 1 on the Billboard 200 chart last month. He also was featured on a string of hits by other artists, including Drake and Eminem, that came out while he was incarcerated - and he recorded a verse for the Drake/Jay-Z collaboration "Light Up" over on the phone for a "Rikers Remix" that made the rounds online.
President Barack Obama recently told Rolling Stone he has some Lil Wayne music on his iPod. And former President Bill Clinton praised the rapper's abilities during a phone interview with a Pittsburgh radio station Tuesday, adding that "what I hope will happen is that he has a good life now."
The Associated Press contributed to this story.