Used in exclamatory or interrogative contexts to express degree or extent, often with an emotional nuance.
どんなに嬉しかったか、言葉にできない。
I can't put into words how happy I was.
Used in concessive patterns with ても/でも to mean 'no matter how much' or 'even if'. Often followed by a verb or adjective in the ても form.
どんなに忙しくても、運動する時間は作るべきだ。
No matter how busy you are, you should make time to exercise.
No matter how cold it is, he runs outside every day.
どんなに待っても彼は来なかった。
No matter how long I waited, he didn't come.
However expensive it is, he will probably buy that car.
No one understands how sad he is.
No matter how much she studies, she always says she isn't confident.
If I pass, how happy I would be!
どれだけ and どんなに can both mean 'to what extent', but どれだけ often has a quantitative nuance (how much/how many) while どんなに emphasizes emotional degree.
どんなに is the neutral, everyday word for 'how much/to what extent' and for 'no matter how much', while いかに is its more formal, literary counterpart.
どんなに expresses 'how much/to what extent' with a focus on degree or intensity, whereas 何という expresses astonishment at the nature or quality of something.
どんなに is the interrogative/exclamatory 'how much', whereas あんなに is the demonstrative 'that much' referring to a specific known degree.
どんなに asks about degree or intensity ('how much'), while どのように asks about manner or method ('in what way'), so they are not interchangeable despite the similar sound.
そんなに states a specific degree ('that much'), while どんなに asks or exclaims about an unspecified degree ('however much; how much').
Compound of どんな (donna, 'what kind of') + に (ni, adverbial particle). The exact historical derivation is straightforward; the word has been used as an adverb of degree since at least the early modern period.