Prosecute vs Persecute
Prosecuteverb
conduct a prosecution in a court of law
Persecuteverb
cause to suffer
The difference
To prosecute is to bring legal proceedings. To persecute is to oppress or harass, usually over belief or identity.
How to keep them apart
Prosecution happens in a court and may be just; persecution never is.