If you have to go to a court because of a DUI charge you should wear good quality dress clothes. Wear the same type of clothes you would wear to an important job interview in an office. You could also wear the same type of clothes you would wear to a wedding or church. It is important to wear clothes like this because you want to show respect for the court. Whether you like it or not you will not get the prosecutors and judges to exercise dicretion in your favor if you dress with disrespect.
You should never wear a hat, chew gum, or leave your headphones on in the courtroom. NEVER permit your cellphone to be turned on in the courtroom, leave it outside the courtroom where it will not distract anyone.
Judges can get very upset if you wear summer shorts, light flimsy tops, revealing necklines, bare belly buttons, and bare shoulders. I have even seen judges fine people in court for wearing such attire. So be warned that if you do not dress appropriately you will probably not win your case and you will be fined on top of it!
Dress shirts should be tucked in and buttoned up. Belts should be fastened. Shoes should be worn instead of flip-flops / open toed shoes.
If you wear a t-shirt (and this is strongly recommend against it) make sure it does not bear any anti-social slogan, show illegal activities, or have racist things on it.
You should remember to keep your hands out of your pockets.
If your son, daughter, or spouse has been arrested and does not have the appropriate attire, contact the police or the jail where they are being held and bring them appropriate clothing. It is surprising how many accused persons in custody come to court without shoes.