This article addresses the efficient finite element solution of exterior acoustic problems with truncated computational domains surrounded by perfectly matched layers (PMLs). The PML is a popular nonreflecting technique that combines accuracy, computational efficiency, and geometric flexibility. Unfortunately, the effective implementation of the PML for convex domains of general shape is tricky because of the geometric parameters that are required to define the PML medium. In this work, a comprehensive implementation strategy is proposed. This approach, which we call the automatically matched layer (AML) implementation, is versatile and fully automatic for the end-user. With the AML approach, the mesh of the layer is extruded, the required geometric parameters are automatically obtained during the extrusion step, and the practical implementation relies on a simple modification of the Jacobian matrix in the elementwise integrals. The AML implementation is validated and compared with other implementation strategies using numerical benchmarks in two and three dimensions, considering computational domains with regular and nonregular boundaries. A three-dimensional application with a generally shaped domain generated using a convex hull is proposed to illustrate the interest of the AML approach for realistic industrial cases. K E Y W O R D S exterior acoustics, finite element method, Helmholtz equation, perfectly matched layer, wave propagation 1 INTRODUCTION Finite element methods (FEMs) are widely used in academia and industry to simulate acoustic wave propagation phenomena. With these methods, high-frequency oscillatory fields can be represented accurately in realistic settings with complicated geometries thanks to unstructured meshes, curved elements, high-order basis functions and hp-adaptivity. 1 Nevertheless, for many applications occurring in the free space, the computational domain must be truncated, and a specific nonreflecting technique must be used at the artificial boundary of the finite element mesh to represent the outward [Correction added on 6 January 2021, after first online publication: ζ symbols have been corrected to throughout the article.] This is an open access article under the terms of the Creative Commons Attribution License, which permits use, distribution and reproduction in any medium, provided the original work is properly cited.