dereinst
one day
An elevated expression for an indefinite point in the future; one day, sometime later.
Sie träumt davon, dereinst ein eigenes Haus am Meer zu besitzen.
She dreams of one day owning her own house by the sea.

one day / once
Loading your saved state.
one day
An elevated expression for an indefinite point in the future; one day, sometime later.
Sie träumt davon, dereinst ein eigenes Haus am Meer zu besitzen.
She dreams of one day owning her own house by the sea.

'Dereinst' (one day/once) is a very elevated and literary expression. It is practically not used in everyday spoken language. It gives a sentence a poetic or solemn tone.
Er hoffte, man würde sich dereinst an seine Taten erinnern.
He hoped that one day people would remember his deeds.
Whether 'dereinst' (one day/once) refers to the future or the past can be recognized from the tense of the verb. If the verb is in the present or future tense, the future is meant. If it is in a past tense such as the preterite or perfect, the past is meant.
Dieses kleine Dorf wird dereinst eine große Stadt sein.
This small village will one day be a big city.
As an adverb, 'dereinst' (one day/once) can stand in position 1, which triggers inversion (verb in position 2). But it can also be placed after the finite verb inside the sentence.
Dereinst werden Roboter viele Aufgaben übernehmen.
One day, robots will take over many tasks.
back then
'damals' and 'dereinst' can both point to a time outside the present. 'damals' is the normal word for a specific point or period in the past. 'dereinst' sounds elevated, old-fashioned, or literary. In old texts it can mean 'damals' (back then), but it is also used for an indefinite future, in the sense of 'one day'. Learners may confuse the words because both can be connected with 'einst' or 'früher' (formerly / in the past). In everyday language, 'damals' is almost always more natural when talking about the past.

Dereinst wird man vielleicht anders über diese Entscheidung denken.
One day, people may think differently about this decision.
Damals wohnte meine Familie noch in einer kleinen Wohnung am Bahnhof.
Back then, my family was still living in a small apartment near the train station.