diff --git a/src/System/Tianbar/Server.hs b/src/System/Tianbar/Server.hs
--- a/src/System/Tianbar/Server.hs
+++ b/src/System/Tianbar/Server.hs
@@ -27,9 +27,12 @@
                      , stopServer :: IO ()
                      }
 
+localhost :: String
+localhost = "127.0.0.1"
+
 startServer :: Callbacks -> IO Server
 startServer c = do
-    sock <- bindIPv4 "127.0.0.1" $ fromIntegral aNY_PORT
+    sock <- bindIPv4 localhost $ fromIntegral aNY_PORT
     prefix <- replicateM 20 $ randomRIO ('a', 'z')
     plugins <- initialize c :: IO AllPlugins
     thread <- forkIO $ runServer sock prefix plugins
@@ -59,7 +62,7 @@
                              | otherwise = uri
     where uri' = uri { uriScheme = "http:"
                      , uriAuthority = Just URIAuth { uriUserInfo = ""
-                                                   , uriRegName = "localhost"
+                                                   , uriRegName = localhost
                                                    , uriPort = ':' : show portNum
                                                    }
                      , uriPath = "/" ++ prefix ++ uriPath uri
diff --git a/tianbar.cabal b/tianbar.cabal
--- a/tianbar.cabal
+++ b/tianbar.cabal
@@ -1,5 +1,5 @@
 name:                tianbar
-version:             0.4.5.0
+version:             0.4.6.0
 synopsis:            A desktop bar based on WebKit
 description:
   A desktop bar using WebKit for rendering as much as possible.
