The American flag was created to inspire national unity and create a separate identity from Britain. It was created in the midst of the Revolutionary War, a period during which it was very important for the Americans to distance themselves from Britain.
The flag was created by Betsy Ross, a well-connected Philadelphia seamstress who lost two of her husbands during the Revolutionary War. The first flag was finished in May or June of 1776, just before the proclamation of the Declaration of Independence. One year later, the Continental Congress officially adopted it as the national flag in order to increase patriotic pride at a crucial moment in the young history of America.