Remove excess dirt from the outside of the exhaust pipe with a rag, which will make cleaning the inside a less muddy chore.
Run a dry toilet brush in the inside of the exhaust pipes to remove large pieces of debris. Wash out the toilet brush when done.
Mix a few tablespoons of dish soap in a bowl of water.
Dampen the rag with the soap and water solution and run it over the outside of the exhaust pipes until clean.
Dampen the toilet brush with the water and soap solution and run it in and out of the exhaust pipes until the inside looks clean.
Rub a bit of chrome or aluminum polish to the outside of the pipes, depending on what material your exhaust pipes are made of.