The question "When did China come to America?" reflects a common confusion between a nation-state and its people. China as a country has never "come" to America; rather, people from China have immigrated to the United States in several distinct waves over nearly two centuries.
The first significant Chinese immigration began during the California Gold Rush (1848–1855). By 1852, over 20,000 Chinese immigrants had arrived. They later formed the backbone of the Transcontinental Railroad construction (1863–1869), with 12,000–15,000 Chinese laborers performing the most dangerous work for the Central Pacific Railroad.
The Chinese Exclusion Act of 1882 halted nearly all immigration, the first U.S. law to restrict a specific ethnic group. It wasn't repealed until 1943, when China was a WWII ally. During this period, the Chinese population in the U.S. declined sharply.
The Immigration and Nationality Act of 1965 abolished national-origin quotas, opening a new era. Subsequent waves included:
Chinese Americans number over 5 million (including mixed heritage), making them the largest Asian-origin group in the U.S. They contribute profoundly to science, technology, cuisine, arts, and every facet of American life.