diff --git a/src/plugins/imageformats/tiff/qtiffhandler.cpp b/src/plugins/imageformats/tiff/qtiffhandler.cpp
index edb54438a114e2a3cea6ca1aae021332942cddc0..837f9ff5193c047132771e5433301534ed2df251 100644
--- a/src/plugins/imageformats/tiff/qtiffhandler.cpp
+++ b/src/plugins/imageformats/tiff/qtiffhandler.cpp
@@ -272,6 +272,8 @@ bool QTiffHandlerPrivate::readHeaders(QIODevice *device)
         format = QImage::Format_Mono;
     else if (photometric == PHOTOMETRIC_MINISBLACK && bitPerSample == 8 && samplesPerPixel == 1)
         format = QImage::Format_Grayscale8;
+    else if (photometric == PHOTOMETRIC_MINISBLACK && bitPerSample == 16 && samplesPerPixel == 1)
+        format = QImage::Format_Grayscale16;
     else if ((grayscale || photometric == PHOTOMETRIC_PALETTE) && bitPerSample == 8 && samplesPerPixel == 1)
         format = QImage::Format_Indexed8;
     else if (samplesPerPixel < 4)
@@ -402,9 +404,11 @@ bool QTiffHandler::read(QImage *image)
         }
     }
     bool format8bit = (format == QImage::Format_Mono || format == QImage::Format_Indexed8 || format == QImage::Format_Grayscale8);
+    bool format16bit = (format == QImage::Format_Grayscale16);
     bool format64bit = (format == QImage::Format_RGBX64 || format == QImage::Format_RGBA64 || format == QImage::Format_RGBA64_Premultiplied);
 
-    if (format8bit || format64bit) {
+    // Formats we read directly, instead of over RGBA32:
+    if (format8bit || format16bit || format64bit) {
         int bytesPerPixel = image->depth() / 8;
         if (format == QImage::Format_RGBX64)
             bytesPerPixel = 6;
@@ -513,6 +517,7 @@ static QVector<QRgb> effectiveColorTable(const QImage &image)
             colors[i] = qRgba(0, 0, 0, i);
         break;
     case QImage::Format_Grayscale8:
+    case QImage::Format_Grayscale16:
         colors.resize(256);
         for (int i = 0; i < 256; ++i)
             colors[i] = qRgb(i, i, i);
@@ -622,6 +627,7 @@ bool QTiffHandler::write(const QImage &image)
         TIFFClose(tiff);
     } else if (format == QImage::Format_Indexed8
                || format == QImage::Format_Grayscale8
+               || format == QImage::Format_Grayscale16
                || format == QImage::Format_Alpha8) {
         QVector<QRgb> colorTable = effectiveColorTable(image);
         bool isGrayscale = checkGrayscale(colorTable);
@@ -631,7 +637,7 @@ bool QTiffHandler::write(const QImage &image)
                 photometric = PHOTOMETRIC_MINISWHITE;
             if (!TIFFSetField(tiff, TIFFTAG_PHOTOMETRIC, photometric)
                     || !TIFFSetField(tiff, TIFFTAG_COMPRESSION, compression == NoCompression ? COMPRESSION_NONE : COMPRESSION_LZW)
-                    || !TIFFSetField(tiff, TIFFTAG_BITSPERSAMPLE, 8)
+                    || !TIFFSetField(tiff, TIFFTAG_BITSPERSAMPLE, image.depth())
                     || !TIFFSetField(tiff, TIFFTAG_ROWSPERSTRIP, defaultStripSize(tiff))) {
                 TIFFClose(tiff);
                 return false;
diff --git a/tests/auto/tiff/tst_qtiff.cpp b/tests/auto/tiff/tst_qtiff.cpp
index 9c815d57813c20d34f5e6395d896226624a9f37c..b2c55468b79df1ab1dae2d791edf7cb66e04cdd7 100644
--- a/tests/auto/tiff/tst_qtiff.cpp
+++ b/tests/auto/tiff/tst_qtiff.cpp
@@ -85,6 +85,7 @@ private slots:
     void tiled();
 
     void readRgba64();
+    void readGray16();
 
 private:
     QString prefix;
@@ -168,6 +169,7 @@ void tst_qtiff::readImage_data()
     QTest::newRow("tiled_oddsize_grayscale") << QString("tiled_oddsize_grayscale.tiff") << QSize(59, 71);
     QTest::newRow("tiled_oddsize_mono") << QString("tiled_oddsize_mono.tiff") << QSize(59, 71);
     QTest::newRow("16bpc") << QString("16bpc.tiff") << QSize(64, 46);
+    QTest::newRow("gray16") << QString("gray16.tiff") << QSize(64, 46);
 }
 
 void tst_qtiff::readImage()
@@ -178,9 +180,13 @@ void tst_qtiff::readImage()
     QString path = prefix + fileName;
     QImageReader reader(path);
     QVERIFY(reader.canRead());
+    QImage::Format headerFormat = reader.imageFormat();
+    QSize headerSize = reader.size();
     QImage image = reader.read();
     QVERIFY(!image.isNull());
     QCOMPARE(image.size(), size);
+    QCOMPARE(image.size(), headerSize);
+    QCOMPARE(image.format(), headerFormat);
 }
 
 void tst_qtiff::readCorruptImage_data()
@@ -386,7 +392,8 @@ void tst_qtiff::readWriteNonDestructive_data()
     QTest::newRow("tiff indexed") << QImage::Format_Indexed8 << QImage::Format_Indexed8 << QImageIOHandler::TransformationMirror;
     QTest::newRow("tiff argb32pm") << QImage::Format_ARGB32_Premultiplied << QImage::Format_ARGB32_Premultiplied << QImageIOHandler::TransformationRotate90;
     QTest::newRow("tiff rgb32") << QImage::Format_RGB32 << QImage::Format_RGB32 << QImageIOHandler::TransformationRotate270;
-    QTest::newRow("tiff grayscale") << QImage::Format_Grayscale8 << QImage::Format_Grayscale8 << QImageIOHandler::TransformationFlip;
+    QTest::newRow("tiff grayscale8") << QImage::Format_Grayscale8 << QImage::Format_Grayscale8 << QImageIOHandler::TransformationFlip;
+    QTest::newRow("tiff grayscale16") << QImage::Format_Grayscale16 << QImage::Format_Grayscale16 << QImageIOHandler::TransformationMirror;
     QTest::newRow("tiff rgb64") << QImage::Format_RGBX64 << QImage::Format_RGBX64 << QImageIOHandler::TransformationNone;
     QTest::newRow("tiff rgba64") << QImage::Format_RGBA64 << QImage::Format_RGBA64 << QImageIOHandler::TransformationRotate90;
     QTest::newRow("tiff rgba64pm") << QImage::Format_RGBA64_Premultiplied << QImage::Format_RGBA64_Premultiplied << QImageIOHandler::TransformationNone;
@@ -609,5 +616,16 @@ void tst_qtiff::readRgba64()
     QCOMPARE(image.format(), QImage::Format_RGBX64);
 }
 
+void tst_qtiff::readGray16()
+{
+    QString path = prefix + QString("gray16.tiff");
+    QImageReader reader(path);
+    QVERIFY(reader.canRead());
+    QCOMPARE(reader.imageFormat(), QImage::Format_Grayscale16);
+    QImage image = reader.read();
+    QVERIFY(!image.isNull());
+    QCOMPARE(image.format(), QImage::Format_Grayscale16);
+}
+
 QTEST_MAIN(tst_qtiff)
 #include "tst_qtiff.moc"
diff --git a/tests/shared/images/tiff.qrc b/tests/shared/images/tiff.qrc
index 91bbf93b112be867fcef9de00566541bce771879..e1ce9daf54d1c0cc475a75b592ea1a225eb96400 100644
--- a/tests/shared/images/tiff.qrc
+++ b/tests/shared/images/tiff.qrc
@@ -51,5 +51,6 @@
         <file>tiff/tiled_oddsize_mono.tiff</file>
         <file>tiff/oddsize_mono.tiff</file>
         <file>tiff/tiled_rgb.tiff</file>
+        <file>tiff/gray16.tiff</file>
     </qresource>
 </RCC>
diff --git a/tests/shared/images/tiff/gray16.tiff b/tests/shared/images/tiff/gray16.tiff
new file mode 100644
index 0000000000000000000000000000000000000000..aeeb0458d54972dd1a686052efddf68d8328866b
Binary files /dev/null and b/tests/shared/images/tiff/gray16.tiff differ