A luminaire comprising: a heatsink comprising: a rim having a first rim section, a second rim section and an intermediate rim section in between the first rim section and the second rim section, a first heatsink region comprising a mounting region and a plurality of first fins (31, 32) extending from the mounting region to at least one of the first rim section and the second rim section, and a second heatsink region comprising a plurality of second fins looping from the intermediate rim section; wherein at least a portion of gaps allows air flowing therethrough at a direction from a first side of the mounting region and a second side of the mounting region opposite the first side, or vice versa, which gaps are delimited by the first fins (31, 32), the second fins and/or the rim; a light module mounted in the mounting region and thermally coupled to the first heatsink region, the light module comprising at least one light engine and a controller for the at least one light engine; and characterized by a sensor mounted on the second heatsink region, the sensor being communicatively coupled to the controller, the controller being adapted to control the at least one light engine in response to a sensor signal from the sensor. a heatsink comprising: a rim having a first rim section, a second rim section and an intermediate rim section in between the first rim section and the second rim section, a first heatsink region comprising a mounting region and a plurality of first fins (31, 32) extending from the mounting region to at least one of the first rim section and the second rim section, and a second heatsink region comprising a plurality of second fins looping from the intermediate rim section; wherein at least a portion of gaps allows air flowing therethrough at a direction from a first side of the mounting region and a second side of the mounting region opposite the first side, or vice versa, which gaps are delimited by the first fins (31, 32), the second fins and/or the rim; a rim having a first rim section, a second rim section and an intermediate rim section in between the first rim section and the second rim section, a first heatsink region comprising a mounting region and a plurality of first fins (31, 32) extending from the mounting region to at least one of the first rim section and the second rim section, and a second heatsink region comprising a plurality of second fins looping from the intermediate rim section; wherein at least a portion of gaps allows air flowing therethrough at a direction from a first side of the mounting region and a second side of the mounting region opposite the first side, or vice versa, which gaps are delimited by the first fins (31, 32), the second fins and/or the rim; a light module mounted in the mounting region and thermally coupled to the first heatsink region, the light module comprising at least one light engine and a controller for the at least one light engine; and characterized by a sensor mounted on the second heatsink region, the sensor being communicatively coupled to the controller, the controller being adapted to control the at least one light engine in response to a sensor signal from the sensor.