I’m an immigrant from the Philippines who has achieved the ever-elusive American dream. In this dream I get to work as a user experience leader at Google where I also serve as the executive sponsor of the Filipino Googler Network – an employee resource group for Filipinos who work at Google globally. We recently sponsored a celebration of Filipino Independence Day, a holiday that commemorates our national independence on June 12, 1898.

Later this week we are also celebrating the 4th of July holiday in the U.S., commemorating the Declaration of Independence of the United States of America from the British on July 4, 1776. This story has been retold in the amazing Broadway musical, Hamilton.

These two days celebrating my two countries’ independence are somewhat connected.

Ferdinand Magellan

The archipelago we now know as the Philippines were “discovered” by the Spanish explorer, Ferdinand Magellan, in 1521 who claimed them for Spain while converting the indigenous people to Roman Catholicism. Magellan didn’t get much further as he was killed in the Battle of Mactan by the warriors of Lapu-Lapu, a native chieftain now considered a national hero.

In 1543 another Spanish explorer, Ruy López de Villalobos, christened the archipelago Las Islas Filipinas after King Philip II of Spain. It became a Spanish colony in 1565 after later Spanish expeditions arrived from Mexico to establish the first foreign settlements, kicking off decades of regional political and religious wars involving Brunei, Taiwan, Indonesia, and rival Dutch and Portuguese forces. By the end of the 16th century, Spain was able to settle into full-blown colonization, spreading Christianity while exporting its resources (i.e. sugar) to the old world. Spanish culture greatly influenced the development of the Filipino culture, primarily through trade via Mexico through the Manila-Acapulco trade route.

Spanish colonization ended in 1898 when Filipino revolutionaries, now considered national heroes, rose up against Spanish forces and, with American help (spurred on by the Spanish-American war that started in Cuba), won their independence on June 12, 1898. As part of the 1898 Treaty of Paris, the United States gained control of Cuba and annexed Puerto Rico, Guam, and the Philippines.

The Filipinos felt betrayed as annexation wasn’t part of their agreement with the Americans. Thus began the Philippine-American War. Because of the Americans’ overwhelming technology and resources, the Filipinos quickly turned to guerrilla fighting tactics. The bulk of the war took 3 years to play out but took another 12 for local insurrections to fully end. During this time the Philippines first became an American territory then a commonwealth that slowly inched towards independence. Surprisingly, much of the support for independence came from U.S. industries. As a commonwealth, Philippine goods were not taxed as foreign, keeping costs low which made them difficult to compete against. An independent country would no longer enjoy this advantage, so affected industries were supportive of Philippine independence.

In 1941, just 10 hours after the surprise attack on Pearl Harbor, the Japanese also launched a surprise attack and invasion of the Philippines, successfully pushing the American forces out. My dad was born in 1944 in the middle of the war. Japanese forces occupied his hometown, forcing my family into hiding into the mountains. A great uncle of mine was a resistance fighter who fought, was captured, and survived the Bataan Death March. I remember being told that he had to eat the leather from his shoes in order to survive.

The Japanese occupation lasted throughout most of WWII. Primarily due to the horrible Battle of Manila in 1945, the city became the 2nd most destroyed Allied city of the war. WWII was as traumatic as you might imagine for a country that served both as a base of operations and battlefield for both sides of the war. World War II finally ended after the United States dropped atom bombs on the cities of Hiroshima and Nagasaki in early August 1945, prompting the Japanese to surrender.

Through the Treaty of Manila, the Philippines finally gained its independence on July 4, 1946. The Americans wanted to continue the custom of celebrating the 4th of July as independence day, deciding it was appropriate for the Philippines as well. The presidential administration of Diosdado Macapagal, who served from 1961 to 1965, changed the official day of independence back to June 12, the original date of independence from Spain in 1898. That has been the official date of Philippine independence ever since.