At the end of the Qin Dynasty(221-206 B.C.) the State of Chu and the State of Han fought for control for the country. Xiang Yu, the king of Chu, was besieged(包围) at a place called Gaixia by the Han army led by Liu Bang. Xiang Yu was in a desperate situation, with little food and only a few soliders. At night, the surrounding Han troops started to sing Chu folk songs. Xiang Yu was very surprised at this, and said:"Has Liu Bang occupied the whole of Chu? How can he have drafted so many Chu people into his army?" Then he fled together with the remainder of his forces.
This idiom is used metaphorically to mean to be in a helpless and critical situation, surrounded by the enemy on all sides.

项羽和刘邦原来约定以鸿沟(在今河南荣县境贾鲁河)东西边作为界限,互不侵犯。后来刘邦听从张良和陈平的规劝,觉得应该趁项羽衰弱的时候消灭他,就又和韩信、彭越、刘贾会合兵力追击正在向东开往彭城(即今江苏徐州)的项羽部队。终于布置了几层兵力,把项羽紧紧围在垓下(在今安徽灵璧县东南)。这时,项羽手下的兵士已经很少,粮食又没有了。夜里听见四面围住他的军队都唱起楚地的民歌,不禁非常吃惊地说:“刘邦已经得到了楚地了吗?为什么他的部队里面楚人这么多呢?”说看,心里已丧失了斗志,便从床上爬起来,在营帐里面喝酒,并和他最宠爱的妃子虞姬一同唱歌。唱完,直掉眼泪,在一旁的人也非常难过,都觉得抬不起头来。虞姬自刎于项羽的马前,项羽英雄末路,带了仅剩兵卒至乌江,最终自刎于江边。
以后人们就用“四面楚歌”这个词,形容人们遭受各方面攻击或逼迫,而陷于孤立窘迫的境地。凡是陷于此种境地者,其命运往往是很悲惨的。例如某人因经常与坏人为伍,不事生产,游手好闲,但后来却被那些坏人逼迫得无以为生,而求助于别人时,别人又因他平日行为太坏,绝不同情理睬,这人所处的境地便是“四面楚歌”。