auf
on
Indicates a position on a horizontal surface. Answers the question 'Wo?' (where?) and is used with the dative.
Der Schlüssel liegt auf dem Tisch.
The key is lying on the table.

on / onto / open
Loading your saved state.
on
Indicates a position on a horizontal surface. Answers the question 'Wo?' (where?) and is used with the dative.
Der Schlüssel liegt auf dem Tisch.
The key is lying on the table.

'Auf' is a two-way preposition. It is used with the dative for a location (question: 'Wo?' / where?) and with the accusative for a direction (question: 'Wohin?' / where to?). This is the most important rule for 'auf.'
Das Buch liegt auf dem Tisch (Dativ).
The book is lying on the table (dative).
'Auf' contracts with the neuter article 'das' to form 'aufs.' This usually happens when a direction is indicated (accusative).
Die Katze springt aufs Dach.
The cat jumps onto the roof.
'Auf' is typically used for positions or movements on a horizontal surface, for example a table, the floor, or a street. It describes contact from above.
Die Tasse steht auf dem Tisch.
The cup is on the table.
'Auf' is used for many public places, offices, and events. Typical examples are: 'auf dem Markt' (at the market), 'auf der Post' (at the post office), 'auf einer Party' (at a party), 'auf einem Konzert' (at a concert).
Wir treffen uns später auf dem Weihnachtsmarkt.
We'll meet later at the Christmas market.
Many verbs are fixed with the preposition 'auf' (+ accusative). Important examples are 'warten auf' (to wait for), 'sich freuen auf' (to look forward to), 'antworten auf' (to answer/respond to), and 'achten auf' (to pay attention to).
Wir freuen uns schon sehr auf den Urlaub.
We're already really looking forward to the vacation.
To indicate the language in which something is said or written, the expression 'auf' + [language] is used. The language usually appears without an article.
Was heißt 'danke' auf Japanisch?
How do you say 'thank you' in Japanese?
In the meaning 'geöffnet' (open), 'auf' behaves like a separable prefix and stands at the end in a main clause. It is often combined with verbs like 'sein' (to be) or 'machen' (to make/do).
Warum ist die Haustür auf?
Why is the front door open?
in
'in' and 'auf' both describe places or movements, but they refer to different kinds of places. You use 'in' when something is inside a room, building, or area, or moves into one. You use 'auf' when something is lying on a surface or moves onto one. In addition, German often uses 'auf' for squares, markets, or events, for example 'auf dem Markt' (at the market) or 'auf einer Feier' (at a party). Learners confuse these words because with some places it is not immediately clear whether German expects 'in' or 'auf'. As a rough guide: for inside spaces, 'in' is more likely; for surfaces or events, 'auf' is more likely.

Vor dem Gespräch legt Tom die Unterlagen auf den Tisch.
Before the meeting, Tom puts the documents on the table.
Frau Becker stellt die Milch in den Kühlschrank.
Ms. Becker puts the milk in the fridge.