diff --git a/include/libcamera/internal/camera_sensor.h b/include/libcamera/internal/camera_sensor.h
index 71d012f795fe..3e98f71b5e7f 100644
--- a/include/libcamera/internal/camera_sensor.h
+++ b/include/libcamera/internal/camera_sensor.h
@@ -53,7 +53,7 @@ public:
 	const MediaEntity *entity() const { return entity_; }
 	const std::vector<unsigned int> &mbusCodes() const { return mbusCodes_; }
 	const std::vector<Size> &sizes() const { return sizes_; }
-	Size resolution() const { return activeArea_.size(); }
+	Size resolution() const;

 	V4L2SubdeviceFormat getFormat(const std::vector<unsigned int> &mbusCodes,
 				      const Size &size) const;
diff --git a/src/libcamera/camera_sensor.cpp b/src/libcamera/camera_sensor.cpp
index a04982971616..edc2c27084ed 100644
--- a/src/libcamera/camera_sensor.cpp
+++ b/src/libcamera/camera_sensor.cpp
@@ -551,10 +551,22 @@ int CameraSensor::initProperties()
  */

 /**
- * \fn CameraSensor::resolution()
  * \brief Retrieve the camera sensor resolution
+ *
+ * The camera sensor resolution is the largest frame size the sensor can produce
+ * or, if the camera sensor embeds and ISP that can up-scale, the pixel area
+ * size.
+ *
+ * \todo Consider if it desirable to distinguish between the maximum resolution
+ * the sensor can produce (also including upscaled ones) and the actual pixel
+ * array size by splitting this method in two.
+ *
  * \return The camera sensor resolution in pixels
  */
+Size CameraSensor::resolution() const
+{
+	return std::min(sizes_.back(), activeArea_.size());
+}

 /**
  * \brief Retrieve the best sensor format for a desired output
