der Angreifer
attacker
A person or group that physically or militarily attacks another person, group, or thing.
Die Polizei konnte den Angreifer schnell überwältigen und festnehmen.
The police were able to quickly overpower and arrest the attacker.

attacker
Loading your saved state.
attacker
A person or group that physically or militarily attacks another person, group, or thing.
Die Polizei konnte den Angreifer schnell überwältigen und festnehmen.
The police were able to quickly overpower and arrest the attacker.

The word is derived from the verb 'angreifen' (to attack). The ending '-er' refers to the person who performs the action. 'Angreifen' itself consists of 'an' and 'greifen', which literally means to reach for someone or something in order to attack.
Der Hund bellte den fremden Angreifer an.
The dog barked at the unfamiliar attacker.
'Der Angreifer' (attacker) belongs to a word family with the verb 'angreifen' (to attack) and the noun 'der Angriff' (attack). All three words refer to the action of an attack.
Die Mannschaft startete einen schnellen Angriff.
The team launched a quick attack.
The context makes clear what kind of attacker is meant. Words like 'Polizei' (police) or 'Verteidigung' (defense) indicate a physical attack, terms like 'Tor' (goal) or 'Stürmer' (striker) indicate sports, and 'Computer' (computer) or 'Netzwerk' (network) indicate the IT field.
Der Angreifer des Fußballteams war heute sehr erfolgreich.
The football team's attacker was very successful today.
In a sports context, 'Angreifer' (attacker) is often combined with adjectives such as 'schnell' (fast), 'gefährlich' (dangerous), or 'erfolgreich' (successful). Typical verbs are 'stoppen' (to stop), 'verteidigen' (to defend), or 'foul spielen' (to foul).
Der gegnerische Angreifer war kaum zu stoppen.
The opposing attacker was almost impossible to stop.
opponent
'der Gegner' and 'der Angreifer' can both mean a person or group on the other side. But 'der Gegner' is more general: it can be someone in sports, in a debate, or in a conflict. An opponent does not have to actively attack. 'der Angreifer' emphasizes that someone launches an attack, plays forward in sports, or attacks a system in IT. Learners may confuse the words because an attacker is often also an opponent. But 'Gegner' describes more the role on the other side, while 'Angreifer' describes the active action of attacking.

Der Angreifer kam durch die Mitte und schoss sofort aufs Tor.
The attacker came through the middle and immediately shot at the goal.
In der Diskussion hörte sie dem Gegner ruhig zu.
In the discussion, she calmly listened to her opponent.