At present, the amount of data from users is increasing exponentially, and most of the data is stored in data centers distributed in different geographic locations. The cost of transferring large amounts of data across geographically distributed data centers can become prohibitive. Therefore, to shorten the data transmission time and reduce the cost of data transmission bandwidth and maintain the load balance of the geographically distributed cloud system, an optimal data placement strategy considering capacity limitation and load balancing in a geographically distributed cloud is proposed. Firstly, the capacity limitation, load balancing, and bandwidth cost of each cloud data center in the geographically distributed cloud are considered, and the data placement problem in the geographically distributed cloud is mathematically modeled. Secondly, the Floyd algorithm is used to model the cost of data transmission bandwidth and find the minimum transmission bandwidth cost. Finally, the Lagrangian relaxation method is used to obtain the optimal data placement scheme for the transmission time. To show the performance advantages of the proposed algorithm, comparative experiments are carried out. When the bandwidth is 15 Mbps, in terms of the Load Balancing Degree (), the proposed algorithm is 40.3% higher than the Hash on average, 35.6% higher than the Closest on average, and 25.7% higher than the CRANE on average. Moreover, the experimental results show that the proposed algorithm can reduce the data transmission cost, and improve the load balancing in a geographically distributed cloud system.