diff --git a/heapsize.cabal b/heapsize.cabal
--- a/heapsize.cabal
+++ b/heapsize.cabal
@@ -1,6 +1,6 @@
 cabal-version:      3.0
 name:               heapsize
-version:            0.2.0
+version:            0.3.0
 license:            BSD-3-Clause
 license-file:       LICENSE
 category:           GHC, Debug, Development
diff --git a/src/HeapSize.hs b/src/HeapSize.hs
--- a/src/HeapSize.hs
+++ b/src/HeapSize.hs
@@ -89,14 +89,11 @@
   { _unHeapsize :: ReaderT HeapsizeState (MaybeT IO) a}
   deriving (Applicative, Functor, Monad, MonadIO, MonadCatch, MonadMask, MonadThrow)
 
-initSize :: Int
-initSize = 10000000
-
 --   A garbage collection is performed before the size is calculated, because
 --   the garbage collector would make heap walks difficult.
 --   Returns `Nothing` if the count is interrupted by a garbage collection
-runHeapsize :: Heapsize a -> IO (Maybe a)
-runHeapsize (Heapsize comp) = do
+runHeapsize :: Int -> Heapsize a -> IO (Maybe a)
+runHeapsize initSize (Heapsize comp) = do
 
   -- initialize the mutable state
   !closuresSeen <- HT.newSized initSize
