träumen
to dream
To experience images, thoughts, and feelings while asleep.
Ich habe letzte Nacht geträumt, dass ich fliegen konnte.
I dreamed last night that I could fly.

to dream
Loading your saved state.
to dream
To experience images, thoughts, and feelings while asleep.
Ich habe letzte Nacht geträumt, dass ich fliegen konnte.
I dreamed last night that I could fly.

When describing the content of a dream or a wish, you use the preposition 'von' followed by the dative. This structure is very typical for the meanings 'to experience while asleep' and 'to wish for something'.
Ich träume oft von meiner Kindheit.
I often dream of my childhood.
The meaning 'to be inattentive' is often used as a command ('Träum nicht!' — Don't daydream!). Whether a dream while asleep or a wish is meant is revealed by the context: time expressions like 'letzte Nacht' (last night) point to a sleeping dream.
Was hat der Lehrer gesagt? Ich habe gerade geträumt.
What did the teacher say? I was just daydreaming.
To describe a complex dream while asleep, a subordinate clause with 'dass' (that) is often used. The conjugated verb of the subordinate clause then comes at the end.
Sie hat geträumt, dass sie eine wichtige Prüfung verpasst.
She dreamed that she missed an important exam.
In the meaning 'to be inattentive', 'träumen' (to daydream) often has a negative or reproachful undertone. It is usually used to tell someone to concentrate.
Träumst du schon wieder? Pass bitte im Unterricht auf!
Are you daydreaming again? Please pay attention in class!
to hope
'hoffen' and 'träumen' can both have to do with wishes for the future. You use 'hoffen' when you wish that something really happens and you have a positive expectation. 'träumen von' is more strongly connected with imagination and big wishes. It can be something very nice, but it often sounds less concrete or less certain. Learners may confuse the words because in both cases you want something positive. When it is about a possible outcome, 'hoffen' fits. When you imagine something in your fantasy or have a big wish, 'träumen von' fits.

Er träumt von einer langen Reise durch Südamerika.
He dreams of a long trip through South America.
Wir hoffen, dass das Wetter am Wochenende gut bleibt.
We hope that the weather stays good over the weekend.