Abstract An inverse breaking line identification problem formulated as an optimal control problem with a suitable PDE constraint is studied. The constraint is a boundary value problem describing the anti-plane equilibrium of an elastic body with a stress-free breaking line under the action of a traction force at the boundary. The behavior of the displacement is observed on a subset of the boundary, and the optimal breaking line is identified by minimizing the <m:math xmlns:m="http://www.w3.org/1998/Math/MathML"> <m:msup> <m:mi>L</m:mi> <m:mn>2</m:mn> </m:msup> </m:math> {L^{2}} -distance between the displacement and the observation. Then the optimal control problem is solved by shape optimization techniques via a Lagrangian approach. Several numerical experiments are carried out to show its performance in diverse situations.