に (ni): destination, time, recipient and existence
に is the most versatile of the five base particles. Its common thread: an arrival point or a fixed point, as opposed to the action frame marked by で.
Use 1: destination of motion
With motion verbs 行く (いく, go), 来る (くる, come) or 帰る (かえる, return), に indicates where you're going.
学校に行く。
がっこう ni いく。
Go to school.
Use 2: precise point in time
For hours, dates, specific days. Vague durations ("in the morning", "yesterday") don't take に.
7時に起きる。
しちじ ni おきる。
Wake up at 7.
Use 3: recipient of an action
The indirect object: who you give to, who you speak to, who you call. In English: "to someone".
友達にプレゼントをあげる。
ともだち ni プレゼント o あげる。
Give a present to a friend.
Note the combo: friend is the indirect object (に), present is the direct object (を).
Use 4: location of existence with ある / いる
With existence verbs (ある for objects, いる for living beings), に marks where it exists. Never で here.
部屋に猫がいる。
へや ni ねこ ga いる。
There's a cat in the room.
猫 (ねこ) takes が (subject of existence), 部屋 (へや) takes に (place of existence).