The symbol ¡ is the twin brother of the inverted question mark, but it is responsible for emotion. It opens an exclamatory sentence or an exclamatory part of a phrase, and the regular ! closes it at the end.
Most often, ¡ appears in short emotional constructions — congratulations, exclamations, calls to action: ¡Felicidades!, ¡Vamos!, ¡Qué suerte! Especially productive are combinations with the pronoun qué — through them Spanish expresses admiration, surprise, horror, or joy: ¡Qué maravilla! (How wonderful!), ¡Qué desastre! (What a disaster!).
When a sentence is both interrogative and emotional, both marks stand together: ¡¿Pero qué estás haciendo?! In informal correspondence, Spaniards like to double or triple the marks for emphasis: ¡¡¡Increíble!!! — and the Academy looks upon this without approval, but language lives its own life.
By the way, in the age of smartphones, young Spaniards often omit the opening marks altogether — writing Qué bien! instead of ¡Qué bien! This is not considered correct, but in messaging apps it is extremely common. Living language is always a little ahead of academic norms, and Spanish is no exception in this respect.