Use Template Haskell to embed file contents directly.

Version on this page:
LTS Haskell 22.22:
Stackage Nightly 2024-05-22:
Latest on Hackage:

See all snapshots file-embed appears in

BSD-3-Clause licensed and maintained by Michael Snoyman
This version can be pinned in stack with:file-embed-,1351

Module documentation for


Use Template Haskell to read a file or all the files in a directory, and turn them into (path, bytestring) pairs embedded in your haskell code.


  • Improve inject documentation #11

Minor cleanup


  • Custom postfix for magic string #7

Minor cleanup