In a statement on Sunday, his club, Qatar's Al Duhail, said Msakni would not play until October at the earliest after injuring his knee.
The World Cup begins on June 14.
The 27-year-old, who had been instrumental in helping Tunisia qualify for the finals, announced on his Instagram page that he was "very sad" to miss the tournament.
His absence is a major blow to Tunisia's hopes of progressing from a group also including Belgium, England and Panama.
Msakni was the team's top scorer with three goals in the team's successful final qualifying round for Russia.
Tunisia, known as the "Carthage Lions", play their first game against England in Volgograd on June 18.
Msakni injured himself playing in a match against Al Sailiya on April 7, which saw his Al Duhail team crowned as Qatari league champions, finishing ahead of second-placed Al Sadd, captained by Barcelona great Xavi Hernandez.