Since the early days under the French domination, patriotic organizations appeared in the within the city, including Dong Kinh Nghia Thuc and Dong Du movements. In March 1929, the first communist party cell was established in Hanoi, which was a very important victory in the thought of proletarian class against bourgeois class and the trend of other countries. And on June 17, 1929, at No. 312 Kham Thien Street, Indochinese Communist Party was officially formed. The party announced its political program and declaration.
Along with the establishment of the Indochinese Communist Party in the north, An Nam Communist Party and Indochinese Communist League were set up in the south and the central region respectively. In March 1930, Nguyen Ai Quoc represented the Communist International to open a conference in Hong Kong to merge the three parties into one. Therefore, on February 3, 1930, the Communist Party of Vietnam was established (in October, it was renamed into Indochinese Communist Party).
In September, 1940, the Japanese fascism overflowed into Hanoi, making local people suffer from both the domination of the French Colonialism and Japanese fascism. On March 9, 1945, Japan staged a coup against France. On August 15, 1945, the German fascism surrendered to the Allies, the puppet and parties which had a closed relation with Japan became puzzled. The revolutionary atmosphere in Hanoi got tense. On August 16, 1945, the national congress in Tan Trao passed "General uprising command” and elected the national committee for central liberation, or provisional government, chaired by President Ho Chi Minh.
Under the guidance of the communist party, people from the north to the south revolted together. The August Revolution reached the comprehensive victory on August 19, which encouraged and boosted rising movements of people nationwide to seize power. On September, 1945, a biggest-ever meeting took place at Ba Dinh Square, attracting the participation of tens of thousands of people. President Ho Chi Minh formally read the Declaration of Independence to announce the world to farther the Democratic Republic of Vietnam. At the first session held on January 6, 1946, the National Assembly decided to select Hanoi as the country’s capital. President Ho Chi Minh got the local agencies and people with 98.4% of votes.