The Philippines declared independence from Spain but failed to win international recognition of its independence, including the United States of America or Spain. The Spanish government later ceded the Philippine archipelago to the United States in the 1898 Treaty of Paris. The Philippines Revolutionary Government did not recognize the treaty and the two sides subsequently fought in what was known as the Philippine–American War.
The United States of America granted independence to the Philippines on July 4, 1946, through the Treaty of Manila. July 4 was chosen as the date by the United States because it corresponds to the United States’ Independence Day, and that day was observed in the Philippines as Independence Day until 1962.
On May 12, 1962, President Diosdado Macapagal issued Presidential Proclamation No. 28, which declared June 12 a special public holiday throughout the Philippines, “… in commemoration of our people’s declaration of their inherent and inalienable right to freedom and independence.”
On August 4, 1964, Republic Act No. 4166 renamed July 4 holiday as “Philippine Republic Day”, proclaimed June 12 as “Philippine Independence Day”, and enjoined all citizens of the Philippines to observe the latter with befitting rites.