The Library of Congress hosts a number of historical treasures, including, as a writer for the Smithsonian Magazine discovered in the library's archives, a video from the 1930s that shows actual Confederate veterans doing their famed "Rebel Yell."
The yell was used as a battle cry by Confederate soldiers, usually during charges. It was never recorded during a battle because audio recording technology was in its infancy during the war. The first known recordings were created in 1859 and 1860, just before the Civil War started. The first popular audio recording device wasn't invented until 1877, 12 years after the war ended.
So, recordings of Civil War veterans from the early 1900s are likely the closest modern people can come to knowing what Union soldiers heard as a Confederate charge barreled at them. Listen to the yell in the video below: