diff --git a/CHANGELOG.md b/CHANGELOG.md
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,11 @@
 # Changelog
 
+## [0.17.0.0] - 2024-08-04
+
+### Changed
+
+* Allow golden tests to perform IO during comparisons
+
 ## [0.16.0.0] - 2024-08-03
 
 ### Changed
diff --git a/src/Test/Syd/Def/Golden.hs b/src/Test/Syd/Def/Golden.hs
--- a/src/Test/Syd/Def/Golden.hs
+++ b/src/Test/Syd/Def/Golden.hs
@@ -34,9 +34,10 @@
         ensureDir $ parent resolvedFile
         SB.writeFile (fromAbsFile resolvedFile) actual,
       goldenTestCompare = \actual expected ->
-        if actual == expected
-          then Nothing
-          else Just $ Context (bytestringsNotEqualButShouldHaveBeenEqual actual expected) (goldenContext fp)
+        pure $
+          if actual == expected
+            then Nothing
+            else Just $ Context (bytestringsNotEqualButShouldHaveBeenEqual actual expected) (goldenContext fp)
     }
 
 -- | Test that the given lazy bytestring is the same as what we find in the given golden file.
@@ -60,11 +61,12 @@
         ensureDir $ parent resolvedFile
         SB.writeFile (fromAbsFile resolvedFile) (LB.toStrict actual),
       goldenTestCompare = \actual expected ->
-        let actualBS = LB.toStrict actual
-            expectedBS = LB.toStrict expected
-         in if actualBS == expectedBS
-              then Nothing
-              else Just $ Context (bytestringsNotEqualButShouldHaveBeenEqual actualBS expectedBS) (goldenContext fp)
+        pure $
+          let actualBS = LB.toStrict actual
+              expectedBS = LB.toStrict expected
+           in if actualBS == expectedBS
+                then Nothing
+                else Just $ Context (bytestringsNotEqualButShouldHaveBeenEqual actualBS expectedBS) (goldenContext fp)
     }
 
 -- | Test that the given lazy bytestring is the same as what we find in the given golden file.
@@ -88,11 +90,12 @@
         ensureDir $ parent resolvedFile
         SB.writeFile (fromAbsFile resolvedFile) (LB.toStrict (SBB.toLazyByteString actual)),
       goldenTestCompare = \actual expected ->
-        let actualBS = LB.toStrict (SBB.toLazyByteString actual)
-            expectedBS = LB.toStrict (SBB.toLazyByteString expected)
-         in if actualBS == expectedBS
-              then Nothing
-              else Just $ Context (bytestringsNotEqualButShouldHaveBeenEqual actualBS expectedBS) (goldenContext fp)
+        pure $
+          let actualBS = LB.toStrict (SBB.toLazyByteString actual)
+              expectedBS = LB.toStrict (SBB.toLazyByteString expected)
+           in if actualBS == expectedBS
+                then Nothing
+                else Just $ Context (bytestringsNotEqualButShouldHaveBeenEqual actualBS expectedBS) (goldenContext fp)
     }
 
 -- | Test that the given text is the same as what we find in the given golden file.
@@ -112,9 +115,10 @@
         ensureDir $ parent resolvedFile
         SB.writeFile (fromAbsFile resolvedFile) (TE.encodeUtf8 actual),
       goldenTestCompare = \actual expected ->
-        if actual == expected
-          then Nothing
-          else Just $ Context (textsNotEqualButShouldHaveBeenEqual actual expected) (goldenContext fp)
+        pure $
+          if actual == expected
+            then Nothing
+            else Just $ Context (textsNotEqualButShouldHaveBeenEqual actual expected) (goldenContext fp)
     }
 
 -- | Test that the given string is the same as what we find in the given golden file.
@@ -134,9 +138,10 @@
         ensureDir $ parent resolvedFile
         SB.writeFile (fromAbsFile resolvedFile) (TE.encodeUtf8 (T.pack actual)),
       goldenTestCompare = \actual expected ->
-        if actual == expected
-          then Nothing
-          else Just $ Context (stringsNotEqualButShouldHaveBeenEqual actual expected) (goldenContext fp)
+        pure $
+          if actual == expected
+            then Nothing
+            else Just $ Context (stringsNotEqualButShouldHaveBeenEqual actual expected) (goldenContext fp)
     }
 
 -- | Test that the show instance has not changed for the given value.
diff --git a/src/Test/Syd/Run.hs b/src/Test/Syd/Run.hs
--- a/src/Test/Syd/Run.hs
+++ b/src/Test/Syd/Run.hs
@@ -298,7 +298,7 @@
     -- | Compare golden output with current output
     --
     -- The first argument is the current output, the second is the golden output
-    goldenTestCompare :: a -> a -> Maybe Assertion
+    goldenTestCompare :: a -> a -> IO (Maybe Assertion)
   }
 
 instance IsTest (GoldenTest a) where
@@ -351,7 +351,8 @@
           else pure (TestFailed, Just GoldenNotFound, Nothing)
       Just golden -> do
         actual <- goldenTestProduce >>= evaluate
-        case goldenTestCompare actual golden of
+        mAssertion <- goldenTestCompare actual golden
+        case mAssertion of
           Nothing -> pure (TestPassed, Nothing, Nothing)
           Just assertion ->
             if testRunSettingGoldenReset
diff --git a/sydtest.cabal b/sydtest.cabal
--- a/sydtest.cabal
+++ b/sydtest.cabal
@@ -5,7 +5,7 @@
 -- see: https://github.com/sol/hpack
 
 name:           sydtest
-version:        0.16.0.0
+version:        0.17.0.0
 synopsis:       A modern testing framework for Haskell with good defaults and advanced testing features.
 description:    A modern testing framework for Haskell with good defaults and advanced testing features. Sydtest aims to make the common easy and the hard possible. See https://github.com/NorfairKing/sydtest#readme for more information.
 category:       Testing
