When the American Revolution broke out in 1775, the colonists weren’t fighting united under a single flag. Instead, most regiments participating in the war for independence against the British fought under their own flags. In June of 1775, the Second Continental Congress met in Philadelphia to create the Continental Army—a unified colonial fighting force—with the hopes of a more organized battle against its colonial oppressors. This led to the creation of what was, essentially, the first “American” flag, the Continental Colors.
On June 14, 1777, the Second Continental Congress took a break from writing the Articles of Confederation and passed a resolution stating that “the flag of the United States be 13 stripes, alternate red and white,” and that “the union be 13 stars, white in a blue field, representing a new constellation.”
– https://www.history.com/news/what-is-flag-day