Here are some ways you can use it:
* Que tal? (How are you?)
* Que tal estás? (How are you? - more formal)
* ¿Qué tal te va? (How are you doing? - more formal)
* ¿Qué tal todo? (How is everything? - more formal)
It's a versatile phrase you can use in many situations, both to greet someone and to ask about their well-being.