Introducing
The Slant team built an AI & it’s awesome
Find the best product instantly
Add to Chrome
Add to Edge
Add to Firefox
Add to Opera
Add to Brave
Add to Safari
Try it now
4.7 star rating
0
Development
Web
What are the best Haskell web frameworks for building RESTful web services?
13
Options
Considered
103
User
Recs.
Feb 20, 2023
Last
Updated
Related Questions
Activity
Have feedback or ideas?
Join our community
on Discord
Ad
13
Options
Considered
Best Haskell web frameworks for building RESTful web services
Price
License
Written in
56
Yesod
-
MIT
Haskell
--
Spock
-
-
-
--
Servant
-
-
-
--
Happstack Lite
-
-
-
--
Scotty
-
-
-
See Full List
56
Yesod
My Rec
ommendation
for
Yesod
My Recommendation for
Yesod
All
7
Pros
4
Cons
2
Specs
Top
Pro
•••
Offers templating for type-safe, well-formed content
While not required, Yesod offers templating through a Shakespearean family of languages to produce page code.
See More
Top
Con
•••
Is hard to customize
Learning how Yesod works internally is hard. It is a large framework with complicated components. Finding the appropriate code and understanding how it contributes to the framework is difficult, meaning developers will struggle.
See More
Specs
License:
MIT
Written in:
Haskell
Repository:
https://github.com/yesodweb/yesod
Price:
free
Top
Pro
•••
Uses type-safe URLs
Ensures that data provided by the URL is type-safe. This means that data in the URL has a definitive type.
See More
Top
Con
•••
Too much template haskell
You actually want to code in haskell and not some DSL with "magic" hidden under the bonnet.
See More
Top
Pro
•••
Can be used without knowing much Haskell
While Yesod is written in Haskell, developers can achieve basic functionality without much investment in the language.
See More
Top
Pro
•••
Lot of batteries included
Login system using many different and modern methods. Route and resources access control
See More
Hide
See All
Get it
here
Recommend
28
8
--
Spock
My Rec
ommendation
for
Spock
My Recommendation for
Spock
All
2
Pros
2
Top
Pro
•••
Type-safe, function-level routes
Spock parses request URLs into well-typed data without requiring your routes to be declared at the type level.
See More
Top
Pro
•••
Small but complete
Unlike scotty it manages to be small and, at the same time, includes all the necessities like sessions and db pool.
See More
Hide
Get it
here
Recommend
19
1
--
Servant
My Rec
ommendation
for
Servant
My Recommendation for
Servant
All
7
Pros
4
Cons
3
Top
Pro
•••
Automatic documentation and Haskell/JS query generation
Routes are defined end-to-end with type declarations. This allows your API to be introspective, serving its own documentation and derived query code, via jQuery for Javascript and servant-client for Haskell.
See More
Top
Con
•••
Complicated internals
Extending Servant's existing functionality can be made difficult by the complexity of its type level machinery. Lucky most use cases are able to avoid this.
See More
Top
Pro
•••
Excellent documentation
We Haskellers are accustomed to flying completely blind when using many libraries, luckily with Servant this isn’t the case. It features comprehensive tutorials, literate haskell examples for many use cases and great Haddock documentation for everything else.
See More
Top
Con
•••
Route specifications and implementations are only connected by their position in a large type list
You actually have to count the index of the entry where you changed the specification, and then go and change the entry at the same index in the list of implementation methods. There is no other indication that the two are connected. This along with complex and verbose route definitions, makes it very hard to safely make changes to an API.
See More
Top
Pro
•••
No Template Haskell
Everything is done within the confines of the existing type system, which helps keep compile times down.
See More
Top
Con
•••
Route definitions are more verbose and complicated than other options
You are required to define a number of separate complicated types and their implementations which are usually spread out over a number of files. This makes it hard to figure out the API.
See More
Top
Pro
•••
Nice ecosystem
Fairly large ecosystem of related modules for additional functionality.
See More
Hide
See All
Get it
here
Recommend
10
3
--
Happstack Lite
My Rec
ommendation
for
Happstack Lite
My Recommendation for
Happstack Lite
All
5
Pros
3
Cons
2
Top
Pro
•••
Has extensive documentation
There is extensive documentation and tutorials for Happstack and Happstack Lite available for use. Documentation and tutorials help programmers write their code; with so many options, programmers will have an easy time learning the framework.
See More
Top
Con
•••
Handles exceptions poorly
When an exception occurs on the server, the error gets printed. By seeing an error that makes no sense to the user, his experience is negatively impacted. Having a negative experience can mean a user never visits the site again.
See More
Top
Pro
•••
Molded through 7+ years of feedback
Happstack has been around for over seven years. During this time developers used the framework and offered feedback to improve it. As a result, it is stable and unlikely to have major changes. Happstack Lite was created from all of this feedback
See More
Top
Con
•••
Allows bad code by not enforcing logic separation
Happstack allows developers to write code for controllers, routing, and models together. Doing so will dirty the code and make maintenance harder.
See More
Top
Pro
•••
Shares all of its components on gitHub
Having open source means that developers can customize the framework and offer suggestions and solutions to the code.
See More
Hide
See All
Get it
here
Recommend
2
--
Scotty
My Rec
ommendation
for
Scotty
My Recommendation for
Scotty
All
4
Pros
3
Cons
1
Top
Pro
•••
Easy to pick up and use
A simple framework cuts development time and costs. To get started, developers only need to understand how to write routing and actions.
See More
Top
Con
•••
Lacks features due to its small size
Since Scotty is small, it does not contain some features that a complex web application may need. Anything that Scotty can't provide must be either found or written, costing developers.
See More
Top
Pro
•••
Available on gitHub
Having the source code on gitHub means developers can easily suggest improvements and error reports. They also have a community that can help with any problems that come up.
See More
Top
Pro
•••
Simple to customize
See More
Hide
See All
Get it
here
Recommend
5
2
--
wai-routes
My Rec
ommendation
for
wai-routes
My Recommendation for
wai-routes
All
8
Pros
7
Cons
1
Top
Pro
•••
Provides type-safe routes
Automatically maps routes to datatypes which are checked at compile time. It uses Template Haskell to reduce boilerplate.
See More
Top
Con
•••
Learning curve
Even though it's a "micro" framework, it has a steep learning curve when using advanced features such as subsites.
See More
Top
Pro
•••
Freely mix "unrouted" handlers with typesafe routing and middleware
Can be used without any routing or Template Haskell. "Unrouted" handlers can be freely mixed and matched with typed routing and middleware.
See More
Top
Pro
•••
Easy to customise
Wai-routes is extremely easy to customise. It's neutral to other parts of the system such as the templating language, or the wai server being used. Wai-routes only targets and provides full access to the wai API. The wai-routes handlers are also simple functions which are passed the request data and the environment and return a Response in IO. Arbitrary middleware, routes, and handlers can be mixed together to construct an application.
See More
Top
Pro
•••
Lightweight
Performs quite well when compared with other Haskell web frameworks.
See More
Top
Pro
•••
Subsites support
Subsites provide encapsulation and ability compile time enforcement of contracts between main site and subsites.
See More
Top
Pro
•••
Provides nested routes
Nested routes allow reduction of boilerplate code.
See More
Top
Pro
•••
Route annotations
Route annotations provide an easy way to "mark" routes for extra processing.
See More
Hide
See All
Get it
here
Recommend
3
--
Snap
My Rec
ommendation
for
Snap
My Recommendation for
Snap
All
3
Pros
2
Cons
1
Top
Pro
•••
Provides modules for changeable functionality
Snap provides "snaplets". These are self-contained modules of code that provide additional functionality without muddling the core library. Having these resources saves time when developing code.
See More
Top
Con
•••
Outdated documentation
The comprehensive Snap documentation is currently outdated (last activity appears to have been 2013), though Snap itself is under active development. Note that this primarily affects tutorials and guides; the API documentation is generated automatically and remains current.
See More
Top
Pro
•••
Offers an HTML-based templating language
Heist is a templating system which supports HTML5 and XML. Template langugages in general provide shortcuts to longer blocks of code, decreasing the need for development time and knowledge.
See More
Hide
See All
Get it
here
Recommend
6
3
--
Postgrest
My Rec
ommendation
for
Postgrest
My Recommendation for
Postgrest
All
5
Experiences
1
Pros
3
Specs
Top
Pro
•••
Fast
JSON is handled by PostgreSQL which speed is hard to beat in your own applications. Response times as high as 2000 requests/sec on Heroku free tier.
See More
RickZeeland's Experience
Easiest way of turning a PostgreSQL database into a REST API.
See More
Specs
Platforms:
Windows, Linux, Mac, BSD
Top
Pro
•••
Easy to use
See More
Top
Pro
•••
Linux, Windows, FreeBSD, OS-X
Linux, Windows, FreeBSD, OS-X versions available.
See More
Hide
See All
Free
Recommend
2
--
Nested-Routes
My Rec
ommendation
for
Nested-Routes
My Recommendation for
Nested-Routes
All
4
Pros
3
Cons
1
Top
Pro
•••
Embed Attoparsec parsers and regular expressions in a routable url
If you have a data encoding you would like to allow as a path chunk, you can do so by routing with an attoparsec parser or regular expression directly.
See More
Top
Con
•••
Complicated Types
There is a lot of advanced language extensions in use for the engine - if you have a typo somewhere, the errors are practically impossible to understand.
See More
Top
Pro
•••
Nesting of Handlers
The ability to give a handler child handlers turns a list of handlers into a tree of handlers - much easier to maintain.
See More
Top
Pro
•••
Simple and Concise
Routing a RESTful api is very literal in Nested-Routes.
See More
Hide
See All
Get it
here
Recommend
1
--
IHP
My Rec
ommendation
for
IHP
My Recommendation for
IHP
All
7
Experiences
1
Pros
4
Cons
1
Specs
Top
Pro
•••
Easy for beginners
With the code generators even haskell beginners can easily build CRUD apps.
See More
Top
Con
•••
(Small) Server deployment
I'm a bit unclear on the memory requirements for the server (which becomes less of an issue every following year).
See More
CompetentUaIldak's Experience
Have considered Yesod but IHP is very nice and easy (i.e. effortless) to set up.
See More
Specs
License:
MIT
Written in:
Haskell
Repository:
https://github.com/digitallyinduced/ihp
Top
Pro
•••
Under the hood
Code generators, database schema editors, etc. work with Haskell and SQL files, which can also be edited manually, to get 'under the hood'.
See More
Top
Pro
•••
Instant live reloading
Makes for a super smooth development experience.
See More
Top
Pro
•••
HSX
If you have experience with react, you feel right at home with the HSX view syntax.
See More
Hide
See All
0
Recommend
5
--
Apiary
My Rec
ommendation
for
Apiary
My Recommendation for
Apiary
All
3
Pros
2
Cons
1
Top
Con
•••
Mediocre documentation
Users must rely primarily on the example project and auto-generated API documentation (Haddocks). The author of Apiary is not a native English speaker and openly acknowledges this issue.
See More
Top
Pro
•••
Automatically generates API documentation
Apiary generates comprehensive HTML documentation based on your API routes.
See More
Top
Pro
•••
Type-level routes
Apiary provides type modeling, down to URL parameters, ensuring type safety.
See More
Hide
See All
Get it
here
Recommend
1
--
Miso
My Rec
ommendation
for
Miso
My Recommendation for
Miso
All
7
Pros
6
Cons
1
Top
Pro
•••
Fast
See More
Top
Con
•••
Bloated
Requires nix, ghcjs, and a lot of other sources of significant technical debt to the project.
See More
Top
Pro
•••
Easy
See More
Top
Pro
•••
Isomorphic
See More
Top
Pro
•••
Virtual DOM
See More
Top
Pro
•••
Type-sharing
See More
Top
Pro
•••
Type-safe routing
See More
Hide
See All
0
Recommend
2
1
--
Growler
My Rec
ommendation
for
Growler
My Recommendation for
Growler
All
2
Pros
1
Cons
1
Top
Pro
•••
Clean, simple route building
Growler improves on Scotty's route building functions, allowing hierarchical declarations rather than requiring each endpoint to be fully specified.
See More
Top
Con
•••
Potentially unstable API
Growler is still at an experimental stage and users are warned that breaking changes may happen between versions.
See More
Hide
Get it
here
Recommend
1
Don't see your favorite option? Add it.
Built By the Slant team
Find the best product instantly.
4.7 star rating
Add to Chrome
Add to Edge
Add to Firefox
Add to Opera
Add to Brave
Add to Safari
Try it now - it's free
One sec!
Are you sure that you want to abandon your hard work?
Delete Work
Continue working
{}
undefined
url next
price drop