When was New York City the capital of the U.S.? by New York City was named the capital of America in 1788 and remained so until 1800, when Washington, D.C. was so named.