William IV was the count of Weimar and Orlamünde after the death of his father, William III. In 1046, Eckard II, Margrave of Meissen, died and willed his margraviate to the Emperor Henry III. The emperor received it and promptly granted it to William, who, through the second marriage of his mother Oda, inherited also the Ostmark from the Margrave Dedi. With the loss of the Thuringian march, William had the same territory as the old Margrave Eckard II.
On the death of the Emperor in 1056, he was a loyal follower of the regent, the Empress Agnes of Poitou. He was highly in favour with the empress, who gave him command alongside Eppo, Bishop of Naumburg, of the army in the campaign in support of Andrew I of Hungary against his brother Bela, Duke of Nitra. The German army was soon in retreat and, at the Theben Pass near Wieselburg, William and Eppo were captured. However, Bela's son Geza, impressed by William's courage, induced his father to not only release him, but give him his daughter Sophia in marriage. Before the two could be wed, however, William fell ill and died on his homeward journey in 1062.