diff --git a/ChangeLog.md b/ChangeLog.md
--- a/ChangeLog.md
+++ b/ChangeLog.md
@@ -1,3 +1,6 @@
+## 0.3.0.3
+* Removed the use of the deprecated forkPingThread and replaced it with the recommended withPingThread. [#1700](https://github.com/yesodweb/yesod/pull/1700)
+
 ## 0.3.0.2
 
 * `sendClose` and `sendPing` correctly find the `Connection` from `WebSocketsT`
diff --git a/Yesod/WebSockets.hs b/Yesod/WebSockets.hs
--- a/Yesod/WebSockets.hs
+++ b/Yesod/WebSockets.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE CPP #-}
 {-# LANGUAGE FlexibleContexts      #-}
 {-# LANGUAGE MultiParamTypeClasses #-}
 module Yesod.WebSockets
@@ -117,8 +118,14 @@
                     rhead
                     (\pconn -> do
                         conn <- WS.acceptRequestWith pconn ar
+                        let app = runInIO $ runReaderT inner conn
+#if MIN_VERSION_websockets(0,12,6)
+                        WS.withPingThread conn 30 (pure ()) $ app
+#else
                         WS.forkPingThread conn 30
-                        runInIO $ runReaderT inner conn)
+                        app
+#endif
+                    )
                     src
                     sink
 
diff --git a/yesod-websockets.cabal b/yesod-websockets.cabal
--- a/yesod-websockets.cabal
+++ b/yesod-websockets.cabal
@@ -1,5 +1,6 @@
+cabal-version:       >=1.10
 name:                yesod-websockets
-version:             0.3.0.2
+version:             0.3.0.3
 synopsis:            WebSockets support for Yesod
 homepage:            https://github.com/yesodweb/yesod
 license:             MIT
@@ -8,13 +9,13 @@
 maintainer:          michael@snoyman.com
 category:            Web
 build-type:          Simple
-cabal-version:       >=1.8
 description:         API docs and the README are available at <http://www.stackage.org/package/yesod-websockets>
 extra-source-files:  README.md ChangeLog.md
 
 library
+  default-language:    Haskell2010
   exposed-modules:     Yesod.WebSockets
-  build-depends:       base              >= 4.5 && < 5
+  build-depends:       base              >= 4.10 && < 5
                      , conduit           >= 1.3
                      , mtl
                      , transformers      >= 0.2
