We consider an adaptive finite element method with arbitrary but fixed polynomial degree p ≥ 1, where adaptivity is driven by an edge-based residual error estimator. Based on the modified maximum criterion from [Diening et al, Found. Comput. Math. 16, 2016], we propose a goal-oriented adaptive algorithm and prove that it is instance optimal. Numerical experiments underline our theoretical findings.Date: July 31, 2019. 2010 Mathematics Subject Classification. 65N30, 41A25, 65N12, 65N50. Key words and phrases. Adaptive finite element method, goal-oriented algorithm, quantity of interest, maximum marking strategy, convergence, instance optimality.Acknowledgement: The authors acknowledge support through the Austrian Science Fund (FWF) through the doctoral school Dissipation and dispersion in nonlinear PDEs (grant W1245), the special research program Taming complexity in PDE systems (grant SFB F65), and the stand-alone project Optimal adaptivity for BEM and FEM-BEM coupling (grant P27005).