The end of the Indian Wars in 1885 marked the end of threats to settlers in the West, sparking mass migration. The population of California rose by over 600,000 people between 1890 and 1900. Barbed wire was invented in 1874, fencing off the Great Plains and ending the era of cattle drives and cowboys. Railroads were built through the West in the late 1800s, connecting new territories and encouraging settlement through land grants from the government. The railroads reduced costs and increased access, further opening the West to migration.