The athlete said it was a "tough decision", adding: "The sickness I had two weeks ago was a big setback."
He thrilled spectators at the London Olympics over 5,000m and 10,000m and was due to run both distances in Scotland.
Mo Farah presents beautiful twins girls in HELLO!
Mo Farah said it had been a "tough decision" to withdraw
In his statement Mo added: "Training is getting better but I need another few weeks to get back to the level I was at in 2012 and 2013.
"I really wanted to add the Commonwealth titles to my Olympic and World Championships, but the event is coming a few weeks too soon for me.
"My body is telling me it's not ready to race yet."
Mo Farah collapses in March 2014 after running a half marathon
It's been a tough year for Mo – in March he collapsed while running the New York half marathon. In dramatic scenes he fainted after crossing the finishing line and later admitted that he had been "seeing stars for the last four miles".
Thursday's news is disappointing because he was one of the big draws for the Games, which will involve 4,500 sportsmen and women competing in 17 disciplines from 23 July until 3 August.
The Commonwealth tournament is known as "the friendly Games", and no one provides a better buzz than Mo.
Fans will miss their Somali-born idol's infectious 'Mobot' victory celebrations. At London, his followers got used to him striking the pose, before running over to hug his wife Tania and stepdaughter Rihanna.
The spectacular opening ceremony in Glasgow presided over by the Queen
The couple have now gone on to have twins Aisha and Amani, whom he introduced in a heartwarming photo shoot in HELLO! just days after they were born.
He said their birth in 2012 was the icing on the cake after his sporting achievements.
"I dreamt of becoming an Olympic champion and to do it twice in your country with a stadium of 80,000 people shouting your name, it doesn't get better than that," he told HELLO!
"Then for my wife to have two healthy little girls, well there's no way to describe it."