diff --git a/Text/StringLike.hs b/Text/StringLike.hs
--- a/Text/StringLike.hs
+++ b/Text/StringLike.hs
@@ -3,13 +3,16 @@
 -- | /WARNING/: This module is /not/ intended for use outside the TagSoup library.
 --
 --   This module provides an abstraction for String's as used inside TagSoup. It allows
---   TagSoup to work with String (list of Char), ByteString.Char8 and ByteString.Lazy.Char8.
+--   TagSoup to work with String (list of Char), ByteString.Char8, ByteString.Lazy.Char8,
+--   Data.Text and Data.Text.Lazy.
 module Text.StringLike where
 
 import Data.Typeable
 
 import qualified Data.ByteString.Char8 as BS
 import qualified Data.ByteString.Lazy.Char8 as LBS
+import qualified Data.Text as T
+import qualified Data.Text.Lazy as LT
 
 
 -- | A class to generalise TagSoup parsing over many types of string-like types.
@@ -75,3 +78,25 @@
     strNull = LBS.null
     cons = LBS.cons
     append = LBS.append
+
+instance StringLike T.Text where
+    uncons = T.uncons
+    toString = T.unpack
+    fromString = T.pack
+    fromChar = T.singleton
+    strConcat = T.concat
+    empty = T.empty
+    strNull = T.null
+    cons = T.cons
+    append = T.append
+
+instance StringLike LT.Text where
+    uncons = LT.uncons
+    toString = LT.unpack
+    fromString = LT.pack
+    fromChar = LT.singleton
+    strConcat = LT.concat
+    empty = LT.empty
+    strNull = LT.null
+    cons = LT.cons
+    append = LT.append
diff --git a/tagsoup.cabal b/tagsoup.cabal
--- a/tagsoup.cabal
+++ b/tagsoup.cabal
@@ -1,6 +1,6 @@
 cabal-version:  >= 1.6
 name:           tagsoup
-version:        0.12.1
+version:        0.12.2
 copyright:      Neil Mitchell 2006-2011
 author:         Neil Mitchell <ndmitchell@gmail.com>
 maintainer:     Neil Mitchell <ndmitchell@gmail.com>
@@ -20,6 +20,10 @@
 extra-source-files:
     tagsoup.htm
 
+source-repository head
+    type:     darcs
+    location: http://community.haskell.org/~ndm/darcs/tagsoup/
+
 flag testprog
     default: False
     description: Build the test program
@@ -29,7 +33,7 @@
     description: Build with Download module
 
 library
-    build-depends: base == 4.*, containers, bytestring
+    build-depends: base == 4.*, containers, bytestring, text
 
     if flag(download)
         build-depends: network
