🎁 Free starter workshopHaving a SW issue?
Back to blog
TechnologyAPIBackendGraphQL

REST vs. GraphQL in 2026: What to Choose for Your App

Lukáš HusoAugust 19, 20266 min read
REST vs. GraphQL in 2026: What to Choose for Your App
Photo: Chris Ried / Unsplash

When designing the backend of a new application, the question comes up sooner or later: REST or GraphQL? The answer from practice is less dramatic than internet flame wars suggest: most projects are well served by a well-designed REST API. GraphQL pays off where you have a complex data model and multiple different clients. Let's break it down.

The basic principles

REST organizes an API around resources. Each resource has its URL and is manipulated with standard HTTP methods:

GET    /api/customers        → list of customers
GET    /api/customers/42     → customer 42 detail
POST   /api/customers        → create a customer
PUT    /api/customers/42     → update a customer
DELETE /api/customers/42     → delete a customer

GraphQL exposes a single endpoint and the client asks for exactly the data it needs:

query {
  customer(id: 42) {
    name
    email
    orders(last: 5) {
      number
      total
    }
  }
}

The philosophical difference: with REST, the server decides the shape of the response; with GraphQL, the client does.

Overfetching and underfetching in practice

The main argument for GraphQL is called overfetching/underfetching. What does it mean in practice?

Overfetching: the /api/customers/42 endpoint returns the whole customer object — 40 fields including the billing address and consent history. But the mobile app only needs the name and e-mail on its screen. You transfer useless data, and on a slow mobile connection it shows.

Underfetching: the order detail screen needs the order, the customer and the shipping status. With REST that means three sequential requests; with GraphQL a single query.

Sounds like a clear win for GraphQL — except REST has battle-tested answers to both: a ?fields=name,email parameter for field selection, composite endpoints like /api/orders/42/summary tailored to a specific screen, or ?include=customer,shipping. Less elegant, but it works and carries far less infrastructure.

Where REST wins

  • Simplicity and development speed. You write and test a REST endpoint in a fraction of the time. No schema, no resolvers, no specialized client library.
  • HTTP caching for free. GET /api/products gets cached on a CDN, in the browser and on a reverse proxy without a single line of code. GraphQL POSTs to one endpoint — caching is on you.
  • Public APIs and integrations. When third parties consume your API, REST is the lingua franca. Accounting systems, payment gateways, carriers — they all speak REST.
  • Debugging and monitoring. A REST error is visible in the access log at a glance (404 on a specific URL). With GraphQL every request is a POST to /graphql and you have to log deeper.

Where GraphQL wins

  • Multiple clients with different needs. The web wants full data, the mobile app a minimum, the partner portal something in between. With GraphQL each client asks for its own — you don't maintain three sets of endpoints.
  • A complex, interconnected data model. Social features, tree structures, dashboards composing data from many entities. Where REST would mean a cascade of requests, GraphQL sends one query.
  • A fast-moving frontend. The product team iterates screens weekly? With GraphQL the frontend changes its own query and the backend stays untouched.
  • A strongly typed schema. The GraphQL schema is a machine-readable contract — you generate TypeScript types, documentation and mock data from it.

The maintenance costs nobody talks about

GraphQL isn't free, even though it's open source:

  1. The N+1 problem. A naive resolver makes 101 database queries for a list of 100 orders. The remedies (dataloaders, batching) require expertise.
  2. Query security. A client can send a deeply nested query that takes down your database. You need depth limits, complexity limits and query-level rate limiting.
  3. Field-level authorization. With REST you protect endpoints; with GraphQL you must control who may read which field of which type. That's an order of magnitude more work.
  4. Versioning. REST solves versions with /api/v2/.... GraphQL bets on schema evolution (deprecated fields) — it works, but requires discipline.

For a smaller team, these items easily swallow the savings GraphQL brought on the client side.

Decision table

CriterionRESTGraphQL
Simple CRUD (booking, e-shop, internal system)✅ clear choiceunnecessary overhead
A single web clientunnecessary overhead
Mobile app + web + partnersworks with composite endpoints✅ strong suit
Complex connected data (dashboards, social features)request cascades✅ one query
Public API for third parties✅ the standardrarely
CDN caching✅ freecustom layer needed
Small team, fast deliveryhigher entry cost

Our take from practice

In most projects we build — booking systems, internal apps, e-shops, CRMs — we choose well-designed REST: consistent naming, pagination, filtering, composite endpoints for mobile screens. It's the cheapest path to a maintainable backend, and the client doesn't pay for complexity they won't use. How we think about API design as the foundation of the whole application is covered in our API-first approach article.

We reach for GraphQL when a project meets at least two criteria from the right column — typically a product with a mobile app, web and admin over a rich data model. And even then often hybrid: GraphQL for internal clients, REST for public integrations.

The technology choice always serves the business, not the other way round — the same principle we recommend when choosing a technology for a web application.

Summary

  • REST is the default choice: cheaper to build and maintain, caching for free, the standard for integrations.
  • GraphQL pays off with multiple clients over a complex data model — and carries its own operational costs (N+1, query security, field authorization).
  • Badly designed REST won't be saved by GraphQL and vice versa. API design quality matters more than the technology chosen.

Building a backend for your app? We offer backend and API development for a monthly subscription. Get a price in the configurator, or discuss your data model with us on a consultation — we'll recommend the approach that fits your project, not the fashion.

Get your custom price

Our configurator shows you an indicative price for your project in 2 minutes.

Related Articles

API-First Approach: Why Start with the Backend
TechnologyAPIBackend

API-First Approach: Why Start with the Backend

What API-first development means, its benefits, and how it can save time and money. REST vs GraphQL, documentation, and real-world experience.

March 17, 20269 min read
How to Choose the Right Technology for Your Web Application
TechnologyTechnologyWeb

How to Choose the Right Technology for Your Web Application

A guide to selecting the technology stack for your next web project. We compare React, Next.js, Vue, and other frameworks.

January 15, 20252 min read
Serverless Architecture: When It's Worth It and When It's Not
TechnologyServerlessCloud

Serverless Architecture: When It's Worth It and When It's Not

A practical breakdown of serverless architecture. When it saves money, when it doesn't, vendor lock-in risks, and which projects truly benefit.

April 21, 20269 min read