"Huh" is a sound people make when they don't understand what's being said or are surprised by something. It can be like a question mark in speech.
When you hear someone say "huh", it usually means they didn't catch what the other person was saying or want to ask for clarification. They might even repeat what the other person just said, trying to make sure they got it right. Sometimes "huh" is used when someone is thinking really hard about something and needs a moment to process it. It can be like a little pause button in conversation.
How common is "huh"?
Word huh is considered uncommon in modern English. It appears most frequently in fiction texts and less often in other writings.
Definitions
interjection
(with falling pitch) used to express amusement or subtle surprise.
Example: Huh! I'm sure I locked it when I left.
Used to express doubt or confusion.
Example: Huh? Where did they go?
(with rising pitch) Used to reinforce a question.
Example: Where were you last night? Huh?
(with falling pitch) Used either to belittle the issuer of a statement/question, or sarcastically to indicate utter agreement, and that the statement being responded to is an extreme understatement. The intonation is changed to distinguish between the two meanings - implied dullness for belittlement, and feigned surprise for utter agreement.
Example: (agreement) A: "Murder is bad." B: "Huh!"
(with rising pitch) Used to indicate that one did not hear what was said.
Example: Huh? Could you speak up?
(with falling pitch) Used to create a tag question.