diff --git i/src/wp-includes/post-functions.php w/src/wp-includes/post-functions.php
index 6d5957b..69bda49 100644
--- i/src/wp-includes/post-functions.php
+++ w/src/wp-includes/post-functions.php
@@ -4907,6 +4907,55 @@ function wp_get_attachment_thumb_file( $post_id = 0 ) {
 }
 
 /**
+ * Retrieve thumbnail file path for an attachment.
+ *
+ * @since 4.4.0
+ *
+ * @param int|null|WP_Post $attachment ID or WP_Post object. Default null.
+ * @param string $size Optional. Attachment size. Default thumbnail.
+ *
+ * @return false|string False on failure. Thumbnail file path on success.
+ */
+function wp_get_attachment_file( $attachment = null, $size = 'thumbnail' ) {
+	$attachment = get_post( $attachment );
+	if ( ! $attachment ) {
+		return false;
+	}
+
+	if ( 'thumb' === $size ) {
+		return wp_get_attachment_thumb_file( $attachment->ID );
+	}
+
+	$image_data = wp_get_attachment_metadata( $attachment->ID );
+	if ( ! is_array( $image_data ) ) {
+		return false;
+	}
+
+	$file = get_attached_file( $attachment->ID );
+
+	 if ( ! $file || ! isset( $image_data['sizes'][ $size ] ) || empty( $image_data['sizes'][ $size ] ) ) {
+		return false;
+	}
+
+	$thumbnail_file = str_replace( basename( $file ), $image_data['sizes'][ $size ]['file'], $file );
+
+	if ( empty( $thumbnail_file ) || ! file_exists( $thumbnail_file ) ) {
+		return false;
+	}
+
+	/**
+	 * Filter the attachment thumbnail file path.
+	 *
+	 * @since 4.4.0
+	 *
+	 * @param string  $thumbnail_file File path to the attachment thumbnail.
+	 * @param WP_Post $post           Attachment object.
+	 * @param string  $size           Attachment size.
+	 */
+	return apply_filters( 'wp_get_attachment_thumbnail_file', $thumbnail_file, $attachment, $size );
+}
+
+/**
  * Retrieve URL for an attachment thumbnail.
  *
  * @since 2.1.0
