A force-push is a Git command that overwrites a remote branch's history, which can permanently discard other people's commits. Normally Git refuses to replace commits on the server that the local copy does not contain, and a force option overrides that refusal.

It matters because it can destroy work. If someone else has pushed commits to the branch, a force-push can remove them from the shared history, and recovering them may be difficult or impossible unless a copy exists elsewhere. When an AI agent has permission to run Git commands, it is one of the actions that people often want to require approval for.

It has legitimate uses, such as cleaning up a personal branch after rewriting its history. Safer variants exist that refuse to overwrite work the pusher has not seen, and hosting services let administrators block force-pushes on important branches. Behavior and settings differ between services.

To limit the risk, protect main branches against force-pushes, prefer the safer option when one is needed, avoid giving agents permission to use it without approval and keep backups of important repositories.