Guilin is located in northern Guangxi, bordering Liuzhou to the west, Laibin to the southwest, Wuzhou to the south, Hezhou to the southeast, and within neighbouring Hunan, Huaihua to the northwest, Shaoyang to the north, and Yongzhou to the east. It has a total area of 27,809 square kilometres (10,737 sq mi). The topography of the area is marked by karst formations. The Li River flows through the city.
- Hills and Mountains: Diecai Hill (叠彩山), Elephant Trunk Hill, Wave-Subduing Hill (伏波山), Lipu Mountains, Kitten Mountain, the highest peak of Guangxi, and Yao Hill (尧山)
- Cave: Reed Flute Cave, Seven-Star Cave
In 314 BC, a small settlement was established along the banks of the Li River.
During the Qin Dynasty’s (221–207 BC) campaigns against the state of Nanyue, the first administration was set up in the area around Guilin.
In 111 BC, during the reign of Emperor Wu of the Han Dynasty, Shi An County was established, which could be regarded as the beginning of the city.
In AD 507, the town was renamed Guizhou.
Guilin prospered in the Tang and Song dynasties but remained a county. The city was also a nexus between the central government and the southwest border, and it was where regular armies were placed to guard that border. Canals were built through the city so that food supplies could be directly transported from the food-productive Yangtze plain to the farthest southwestern point of the empire.
In 1921, Guilin became one of the headquarters of the Northern Expeditionary Army led by Dr. Sun Yat-sen.
In 1940, the city acquired its present name.
In 1981, Guilin was listed by the State Council as one of the four cities (the other three being Beijing, Hangzhou and Suzhou) where the protection of historical and cultural heritage, as well as natural scenery, should be treated as a priority project.