We all know about the trenches of WWI. But I only recently knew that during the Sieges of Petersburg and Vicksburg, there was a lot of trench warfare involved there, as well. My question here is whether or not the trenches of the American Civil War would become inspiration for the trenches of WWI a few decades down the road.
Trenches have been used throughout history. They've always been defensive in nature.
In American history, trenches were even used in the War of 1812 by Andrew Jackson and the Battle of New Orleans, Mexican American War, the Civil War. But they were in far less use than in other wars in Europe.
I'd argue that the Crimean War (1853-1856) and the Russo Japanese War (1904-1905) played a much larger influence in incorporating trenches in European military doctrine. There were numerous European conflicts that utilized trenches as defensive tactics. The Crimean War was the first "modern war" utilizing railroads, telegrams, and modern weaponry in terms of powerful and relatively accurate artillery, new rifles, and so on. It was also much closer to the European imaginary than a distant war in the United States. Great powers fought in the Crimean War and the Russo Japanese War was scrutinized as well as brought surprise as a non-European power had defeated a European power in conventional warfare.
So I would not say that Trench warfare was inspired by the American Civil War specifically, but has been a part of European (and others) military doctrine for many centuries in various contexts.. It was that the nature of the First World War made trenches into a very necessary tactic. Opposing forces would not simply give up ground, so what would they do? They would dig in and entrench themselves to hold the front lines against modern machine guns, rifles, and artillery.
Murray, Nicholas. The Rocky Road to the Great War: The Evolution of Trench Warfare to 1914. Washington, DC: Potomac, 2013.
Sieges of Petersburg and Vicksburg
The key word is siege. Sieges have been fought in trenches for a very long time. People who think this stuff was invented during ACW have probably never heard of a star fort or Vauban; circumvallation and contravallation; parallels or approaches.