As stated in the State of API Report, GraphQL's popularity has grown over the past three years. This is reflected in the GraphQL Report 2024, with 61.5% of survey respondents using GraphQL in production and 15.5% exploring it.
Developers appreciate GraphQL for its structured data (31.1%). They also like its ease of use (28.7%) and type checking (18.7%). These qualities highlight its power to simplify data access and speed up development. GraphQL is also changing how companies in many industries build and deliver great user experiences.
Check out the GraphQL Report 2024
Apart from Meta, which is pioneering the use of GraphQL, Airbnb is moving 10x faster at scale with GraphQL, and Twitter has rebuilt its public API with GraphQL. These examples show that GraphQL can significantly enhance enterprise development.
The debate between GraphQL and RESTFUL APIs continues. However, it's important to remember that GraphQL is better for some uses. It can get the exact data in one request, reducing over- and under-fetching.
You may be contemplating using GraphQL in your next project or feel stuck in a REST environment. In this article, we will discuss 8 examples of successful GraphQL adoptions in enterprises and how companies use this powerful query language to revolutionize their products and services.
#Meta: from mobile applications to the Meta app rewrite
One of the most prominent examples of using GraphQL is Meta, the company that created and open-sourced GraphQL. Back in 2012, Meta was still Facebook. The platform faced many challenges with RESTFUL APIs. These were especially related to over-fetching, versioning, and mobile optimization. The engineering team would have lost significant time if they continued developing with REST. Instead, Meta developed GraphQL. It is a data query language that lets clients specify the data they need from a server. They can do this in a hierarchical and strongly typed way.
Using GraphQL, Facebook can:
- Optimize its data fetching and delivery.
- Reduce code and complexity on the client and the server.
- Iterate faster and more confidently on new features.
Fast-forward to 2015, Facebook introduced GraphQL publicly. With React-based frameworks like Next.js, React, React Native, and Gatsby, developers gained powerful tools to revolutionize development workflows. As of today, React-based frameworks are still the strongest for pulling data from GraphQL APIs.
Check out the GraphQL Report 2024
In 2020, Meta engineers performed a complete rewrite to deliver the new Meta app for a client-first experience. This time, Meta was rearchitected using React and Relay (a client for GraphQL in React), and GraphQL was used to modernize its data-fetching infrastructure (since the old site retrieved data ad-hoc through server-side PHP rendering). This results in Meta's app fetching the right data by default. It enables the development of features in a performance-optimized way.
As said by Meta Engineers Ashley Watkins and Royi Hagigi, “Engineering experience improvements and user experience improvements must go hand in hand”. An advanced tech stack was essential for Meta to deliver the most modern experience.
#Samsung: Using GraphQL to power its customer platform
Samsung is the leader in digital devices. It has explored innovative ways to connect with its customers, one of which is enhancing its digital members’ platform. In its quest to improve customer engagement, Samsung encountered challenges, and GraphQL played a pivotal role.
The members’ platform was initially designed as a mobile-only platform, which prevented Samsung from connecting with customers who bought other devices. Furthermore, Samsung’s subsidiaries suffered from slow development cycles due to a legacy stack. The legacy stack used Abode Experience Manager as a monolithic CMS. This means every time the Marketing team wanted to create a new type of content, they needed support from the development team. As a result, development capability was significantly reduced.
Eventually, Samsung migrated to Hygraph, a GraphQL-native headless CMS. In its new members’ platform, Samsung used a headless architecture.
Hygraph's out-of-the-box GraphQL support allowed frontend developers to concentrate on building features without involving backend developers for API adjustments.
On the other hand, content editors use the content models provided by the developers. They only need to make development requests when a new content model is needed, thus making the editorial experience more scalable.
As a result, Samsung launched the new members’ platform. It works on both mobile and desktop. It cut page update time by half and boosted customer engagement by 15%.
#LinkedIn: Using GraphQL to accelerate product development
LinkedIn is the world’s largest professional network. It has embraced GraphQL to streamline product development.
In 2022, LinkedIn developers shared how they used GraphQL to craft the onboarding process for new use cases for external API partners. An efficiency challenge with REST API led to this decision: LinkedIn had to make a new REST API for each use, and running all external APIs was a high-cost barrier. Only highly-scaled or high-ROI use cases could overcome it.
LinkedIn’s development cycle with REST API
By adopting GraphQL, LinkedIn allows users to explore service capabilities using types. New use cases can be created by defining new GraphQL queries. So no more engineering effort is needed. The GraphQL service will automatically work with its type system for this new query. By doing so, LinkedIn accelerated development by 90% in crafting and externalizing APIs.
Earlier in 2023, LinkedIn developers shared their latest experience adopting GraphQL. This time, they used GraphQL to build member and customer-facing applications. The GraphQL layer is architected in a unique manner, as follows:
The GraphQL-type system is autogenerated by federating individual entity schemas from the Rest.li, LinkedIn's own framework for building and operating microservices.
The GraphQL query execution endpoint is distributed and available on each individual frontend microservice, avoiding the need for a central gateway service and an additional network hop.
Only pre-registered queries are allowed on production servers. This allows for better performance, security, and developer experience.
Linkedin’s GraphQL schema federation from Rest.li artifacts
LinkedIn's example showcases how GraphQL can introduce a paradigm shift that boosts productivity, efficiently handles complex data, and delivers a high-quality user experience.
#Netflix: revolutionizing video content delivery with GraphQL
Netflix started using GraphQL in 2018. Developers chose to use the query language to get data for an internal app called Monet. Netflix replaced REST API with GraphQL. This allowed them to load data from a wide range of sources well and without overfetching, resulting in fewer bandwidth bottlenecks.
Perhaps the success back then contributed to Netflix developers’ confidence in GraphQL. In 2022, Netflix updated its iOS and Android apps. Netflix moved its mobile apps to GraphQL with zero downtime. This required a complete overhaul from the client to the API layer.
This time, GraphQL replaced Netflix’s internal API framework, Falcor. Federated GraphQL now backs mobile apps. It is a distributed approach to APIs where domain teams can independently manage and own specific sections of the API. Netflix moved to GraphQL safely. This was for 100s of millions of customers and caused no disruption.
Netflix’s migration to GraphQL phase 1: Built GraphQL Shim Service on top of Monolith Falcor API
Netflix’s migration to GraphQL phase 2: Replace the GraphQL Shim Service and Legacy API Monolith with GraphQL services that domain teams own
#Telenor: powering video streaming at scale
Telenor is a Norwegian telecom company. It is another example of a company that uses GraphQL. They use it to power their video service.
Telenor needed a scalable and flexible solution to manage the metadata of thousands of videos and movies from various sources. It would deliver them to millions of customers across different platforms and devices.
Telenor chose Hygraph for its strong GraphQL API, no-code schema editor, and easy content editing UI. Hygraph lets Telenor centralize data management and simplifies the process by removing the manual and error-prone work of editing XML files.
Telenor also leveraged GraphQL benefits, such as fetching exactly the data needed, reducing network payload and latency, and enabling faster and easier development and testing. This example shows how GraphQL empowered Telenor to build a scalable and efficient video streaming platform. It demonstrates GraphQL's versatility in the media and entertainment industry. Telenor achieved the following as a result:
- Full GraphQL-native support, including powerful API and ecosystem support
- The API meets performance needs. It has less than 100ms latency on millions of API calls. It is much faster than other commercial GraphQL APIs.
- A high degree of flexibility with the tech stack
- Hygraph enables a quick time to market with the first iteration of the project meeting the 3-month deadline
- Sleek UI, which makes it easy to add quick fixes to the content
- No heavy licensing fees like monolith systems
- Fast feature development
#Zalando: transforming eCommerce with GraphQL Unified Backend-For-Frontend
Zalando, Europe's leading fashion eCommerce giant, faced challenges managing numerous backend services for its web and mobile apps. This led to inconsistent and inefficient data delivery, hindering developers and customers. To tackle this, Zalando implemented GraphQL as a Unified Backend-For-Frontend (UBFF) solution.
To do this, Zalando created a single GraphQL API that all frontend teams could access. Developers can reduce unnecessary data transfers by specifying specific data requirements using GraphQL's declarative queries. Zalando even customized the GraphQL implementation with graphql-jit for further performance optimization.
Zalando’s GraphQL architecture
As a result, developers found the experience smooth. They enjoyed easier data finding, helpful GraphQL tools, and faster deployments. Features' delivery sped up. A single data source reduced duplicate work across platforms. Most importantly, customers benefit from a consistent experience on the web and mobile apps thanks to the single source of truth for product information.
Customer experience is based on consistency, if not the most important factor. Zalando's success story shows the potential of GraphQL for unifying data access and streamlining development. Both are indispensable criteria for delivering a consistent customer experience. It's a powerful example for any organization looking to overcome the challenges of managing multiple backend services and delivering a unified user experience across platforms.
#Booking.com: Federated GraphQL to power a scalable and efficient data system
One notable example of Federated GraphQL use is Booking.com's unified data access layer.
Booking.com first adopted GraphQL to modernize its Perl-based systems. The systems led to scalability issues, and it was hard to maintain the old technologies. In the start, Booking.com explored GraphQL by adding it to their infrastructure. They began with a centralized approach, using GraphQL to facilitate data access across the platform. However, they soon encountered scalability challenges with this setup.
Booking.com acknowledged the need for a more scalable solution. So, it transitioned to a Federated GraphQL architecture. This shift empowered teams to oversee and manage their data domains and work independently, which fosters a more scalable and efficient data system.
As a result of their migration efforts, Booking.com saw a big increase in GraphQL adoption within the company. They now process billions of requests daily. They also witnessed an impressive 600% increase in federation traffic in 2023.
Apart from this main use, Booking.com used Hygraph’s GraphQL-native CMS to build the website for their Technology Playmaker Awards, and Apollo Supergraph to pay off tech debt.
Booking.com continues to explore optimization opportunities with GraphQL. Despite the complexities involved, their journey underscores GraphQL's transformative potential in modernizing legacy systems and fostering developer empowerment.
#New York Times: redesigning the website with React, Relay, and GraphQL
To maintain its position as an industry leader, the New York Times constantly seeks ways to enhance digital experiences to deliver award-winning content to millions of subscribers. The New York Times moved to React, Relay, and GraphQL as it redesigned its website.
Before they adopted GraphQL, React, and Relay, the New York Times had issues with their old stack. The frontend applications struggled with complex data needs. They also had slow network requests and trouble managing the state of components. This led to slower load times. It also caused negative user experiences, making frontend development workflows more complex. Developers dreamed of a single repository. It would be used to create and reuse components. It would also be a place to store and get data.
The classic New York Times format
The New York Times now
As a result, developers overhauled their frontend architecture, and GraphQL served as the backbone. It offered a flexible and efficient way to get data through its precise query language. React was the core of dynamic user interface development. It enabled reusable components and streamlined state management. Relay seamlessly integrates React with GraphQL. It hides the complexities of fetching data, caching, and managing state.
The new stack empowered the New York Times. It lets them build highly responsive, feature-rich applications. They could do this while keeping scalability and performance. This integration made the Times' frontend architecture harmonious, and served its diverse content and engaged its vast audience well.
NYT embraced modern frontend technologies, which allowed them to surpass traditional architectural limits. These technologies improved performance and boosted developer productivity, allowing them to deliver great user experiences on their digital platforms.
#Fast forward to 2024
Choosing between GraphQL and REST is more than a matter of preference. Having looked at so many examples, we aim to demonstrate that adopting GraphQL can change your product development paradigm and propel it forward.
Surely, whether or not to choose GraphQL for your project also depends on your project scope and the development resources available. That's why carefully planning, gathering resources such as the GraphQL Report 2024, and selecting a trustworthy vendor matter, such as Hygraph's GraphQL-native CMS, which has a developer community that actively discusses their projects and always provides guidance with documentation.
We’ve encountered several other developer articles demonstrating their excellent use of GraphQL. Take a look:
- Allegro explored GraphQL's performance tradeoffs
- Coursera’s journey to GraphQL
- GraphQL: A Success Story for PayPal Checkout
- Pinterest does Backend-For-Frontend using GraphQL under Microservices
- Slack evolves API Pagination with Relay Cursor Connections
- GraphQL transformation at Twitch
- Uber used GraphQL to Improve Data Hydration in Customer Care Platform and Beyond
#What’s next
GraphQL offers unmatched possibilities. You can use it to craft dynamic and efficient applications. If you are looking for more statistics and insights on the usage of GraphQL, don’t miss out on our 2024 GraphQL annual report.
The GraphQL Report 2024
Statistics and best practices from prominent GraphQL users.
Check out the report