In 1790, Congress passed the Residence Act, declaring Washington, D.C. as the nation’s permanent capital. But because it took 10 years to build up the land near the Potomac River into a functioning capital, Philadelphia served as the temporary capital until 1800. And although Philadelphia is widely known as a former U.S. capital, you might be surprised to learn that eight towns and cities across Maryland, Pennsylvania, New Jersey, and New York have also briefly claimed to be the capital of the United States.

1. BALTIMORE, MARYLAND

During the Revolutionary War, Congress feared that British soldiers would capture Philadelphia, the location of the First and Second Continental Congresses. So from late December 1776 to late February 1777, delegates to the Second Continental Congress met in downtown Baltimore, Maryland.

They rented a large, three-story house from its owner, Henry Fite, to use as their meeting place. At the Henry Fite house, they received news of George Washington crossing the Delaware River and other signs that the war was turning in their favor. Congress’s next meeting, in early March 1777, was back in Philadelphia. The Henry Fite House burned down in 1860, but thanks to the Sons of the American Revolution, visitors can see a memorial plaque near the site where the house once stood.

2. LANCASTER, PENNSYLVANIA

After the defeat of George Washington at the Battle of Brandywine on September 11, 1777, the Continental Congress left Philadelphia for a safer meeting spot. They traveled 60 miles west to Lancaster, where they convened in the town’s courthouse on September 27. That day, they elected Benjamin Franklin to negotiate a treaty with France, and then decided that they shouldn’t sit tight. They left Lancaster the following day because it wasn’t safe enough from the threat of British forces, thus giving Lancaster the honor of hosting the country's capital for just one day.

3. YORK, PENNSYLVANIA

When the Second Continental Congress delegates left Lancaster, they headed 25 miles west to York, Pennsylvania. They used York’s courthouse as their headquarters from late September 1777 to June 1778, and got quite a bit of work done. The delegates drafted the Articles of Confederation and signed a treaty with France. They returned to Philadelphia in June 1778, after the British had left the City of Brotherly Love.

4. PRINCETON, NEW JERSEY

Fearing that unpaid former Revolutionary War soldiers would riot (there was no tax revenue with which to pay them), Continental Congress delegates moved from Philadelphia to Princeton, New Jersey. From June through November 1783, they met in Nassau Hall, a building on the campus of the College of New Jersey (now called Princeton University). At Nassau Hall, the delegates greeted the U.S.’s first foreign minister (who came from the Netherlands), honored Washington for winning the Revolutionary War, and heard that Britain had signed the Treaty of Paris.

Today, visitors can see Nassau Hall, which is located across from the main gate that separates the campus from the town of Princeton. University administrators have their offices in Nassau Hall, and the building also has a Memorial Atrium to honor the alumni who died fighting for the U.S. in wars.

5. ANNAPOLIS, MARYLAND

From late November 1783 to early June 1784, delegates to the Continental Congress met in Annapolis at the Maryland State House. Although the state house was still under construction, there was a finished portion of the building, called the Old Senate Chamber that they used for business. During Congress’ time at the Maryland State House, Washington officially resigned as the Continental Army’s commander-in-chief, and Congress ratified the Treaty of Paris, preparing to end the Revolutionary War. Now a National Historic Landmark, the Maryland State House is the meeting place for the Maryland General Assembly and is open to visitors.

6. TRENTON, NEW JERSEY

Because the Articles of Confederation didn’t declare one location as the nation’s capital, Congress met in Trenton, a village that some delegates wanted to become the permanent U.S. capital. At the French Arms Tavern, a large house that had been converted to a tavern, 31 delegates convened in November and December 1784. In 2009, New Jersey residents celebrated the 225th anniversary of the two months that Trenton was the U.S. capital with lectures, luncheons, and a tavern trek.

7. NEW YORK, NEW YORK

Federal Hall in 1929. Getty

While in New York City, they inaugurated Washington as the first U.S. president, outlined the rules for public office oaths, and organized departments such as foreign affairs, war, postmaster general, and the treasury. Congress also decided to make Philadelphia the nation’s temporary capital until 1800, when Washington, D.C. would take over as the permanent capital. Federal Hall was sadly demolished in 1812, but 30 years later a new Federal Hall was built on the site—it’s on Wall Street, across from the New York Stock Exchange—and visitors can walk up the steps and admire a hulking statue of Washington.In December 1784, the Continental Congress decided to leave Trenton and head to New York City. From 1785 to 1790, Congress met in downtown Manhattan at Old City Hall (later called Federal Hall).

8. BROOKEVILLE, MARYLAND

On August 24, 1814, during the War of 1812, British forces occupied and burned Washington, D.C. To flee the chaos, President James Madison and his staff traveled 18 miles north of D.C. to the rural town of Brookeville, Maryland, arriving on the 26th, and the group stayed in farmer and postmaster Caleb Bentley’s house.

For one day in Brookeville, Madison conducted all government business: he commanded the U.S. military, safeguarded the Senate’s papers, and had meetings with his cabinet. The next day, British forces had moved on from D.C. to Baltimore, so Madison and his staff returned home. Although the accuracy of the statement is up for debate, Brookeville residents proudly refer to their town as “U.S. Capital for a Day,” and visitors can see Bentley’s house at 205 Market Street—now called the Madison house—on Brookeville's walking tour.