StackShareStackShare
Follow on
StackShare

Discover and share technology stacks from companies around the world.

Follow on

© 2025 StackShare. All rights reserved.

Product

  • Stacks
  • Tools
  • Feed

Company

  • About
  • Contact

Legal

  • Privacy Policy
  • Terms of Service
  1. Stackups
  2. Application & Data
  3. Frameworks
  4. Frameworks
  5. GraphQL vs PHP-MVC

GraphQL vs PHP-MVC

OverviewDecisionsComparisonAlternatives

Overview

PHP-MVC
PHP-MVC
Stacks106
Followers222
Votes3
GraphQL
GraphQL
Stacks34.9K
Followers28.1K
Votes309

GraphQL vs PHP-MVC: What are the differences?

Comparison between GraphQL and PHP-MVC

GraphQL and PHP-MVC are two different technologies used in web development. They have key differences in terms of their architecture, data fetching capabilities, and flexibility.

  1. Architecture: GraphQL is a query language and runtime that allows clients to request specific data from the server. It uses a single endpoint to retrieve data, enabling clients to define their data requirements. On the other hand, PHP-MVC (Model-View-Controller) is a software design pattern that separates the application logic into three components: the model, view, and controller. It provides a structured approach to building web applications but does not have a standardized query language like GraphQL.

  2. Data Fetching: GraphQL provides a flexible way of fetching data by allowing clients to specify their data needs in the query itself. Clients can request only the data they require, reducing unnecessary data transfer and improving performance. In PHP-MVC, data fetching is typically done through server-side logic or by executing database queries. The entire data set is usually returned, and clients need to process and filter the data on their end.

  3. Flexibility: GraphQL offers a high level of flexibility by allowing clients to define the structure of the data they need. Clients can request nested and related data in a single query, eliminating the need for multiple round trips to the server. In PHP-MVC, the data structure is predefined by the server-side logic, and clients have limited control over the data they receive. They may need to make multiple requests or rely on server-side logic to retrieve related data.

  4. Performance: GraphQL can improve performance by reducing over-fetching and under-fetching of data. Clients can request only the required data fields, reducing the data transferred over the network. This can lead to faster response times and improved efficiency. In PHP-MVC, performance optimization relies on server-side code optimization, caching mechanisms, and database query optimization.

  5. Tooling and Ecosystem: GraphQL has a rich tooling ecosystem with libraries and tools available for various programming languages. It has a well-defined specification and community support, making it easier to adopt and integrate into different systems. PHP-MVC, on the other hand, is specific to PHP and has a mature ecosystem with frameworks like Laravel and Symfony. It has a large community and a wide range of resources available.

  6. Learning Curve: GraphQL has a learning curve associated with understanding its query language and concepts. Clients and servers need to be aware of GraphQL-specific syntax and practices. PHP-MVC, though it has its learning curve, follows a more traditional server-side development approach and may be easier to learn for developers with prior experience in PHP or similar languages.

In summary, GraphQL and PHP-MVC differ in their architecture, data fetching capabilities, flexibility, performance, tooling/ecosystem, and learning curve. GraphQL provides a more flexible and efficient way of fetching data, while PHP-MVC offers a structured approach to web development with a mature ecosystem.

Share your Stack

Help developers discover the tools you use. Get visibility for your team's tech choices and contribute to the community's knowledge.

View Docs
CLI (Node.js)
or
Manual

Advice on PHP-MVC, GraphQL

Raj
Raj

Oct 10, 2020

Review

It purely depends on your app needs. Does it need to be scalable, do you have lots of features, OR it is a simple project with very simple needs - many of those parameters clarify which technologies will fit.

If you are looking for a quick solution, that reduces lot of development time, take a look at postgraphile (https://www.graphile.org/postgraphile/). You have to just define the schema and you get the entire graph-ql apis built for you and you can just focus on your frontend.

On frontend, React is good, but also need to remember that it is popular because it introduced one way data writes and in-built virtual dom + diffing to determine which dom to modify. Though personally I liked it, am recently more inclined to Svelte because its lightweightedness and absence of virtual dom and its simplicity compared to the huge ecosystem that React has surrounded itself with.

In all situations, frameworks keep changing over time. What is best today is not considered even good few years from now. What is important is to have the logic in a separate, clean manner void of too many framework related dependencies - that way you can switch one framework with another very easily.

3.77k views3.77k
Comments

Detailed Comparison

PHP-MVC
PHP-MVC
GraphQL
GraphQL

This project is - by intention - NOT a full framework, it's a bare-bone structure, written in purely native PHP ! The php-mvc skeleton tries to be the extremely slimmed down opposite of big frameworks like Zend2, Symfony or Laravel.

GraphQL is a data query language and runtime designed and used at Facebook to request and deliver data to mobile and web apps since 2012.

-
Hierarchical;Product-centric;Client-specified queries;Backwards Compatible;Structured, Arbitrary Code;Application-Layer Protocol;Strongly-typed;Introspective
Statistics
Stacks
106
Stacks
34.9K
Followers
222
Followers
28.1K
Votes
3
Votes
309
Pros & Cons
Pros
  • 3
    Easy to Learn
Pros
  • 75
    Schemas defined by the requests made by the user
  • 63
    Will replace RESTful interfaces
  • 62
    The future of API's
  • 49
    The future of databases
  • 12
    Get many resources in a single request
Cons
  • 4
    Hard to migrate from GraphQL to another technology
  • 4
    More code to type.
  • 2
    Takes longer to build compared to schemaless.
  • 1
    No support for caching
  • 1
    No built in security
Integrations
PHP
PHP
No integrations available

What are some alternatives to PHP-MVC, GraphQL?

Node.js

Node.js

Node.js uses an event-driven, non-blocking I/O model that makes it lightweight and efficient, perfect for data-intensive real-time applications that run across distributed devices.

Rails

Rails

Rails is a web-application framework that includes everything needed to create database-backed web applications according to the Model-View-Controller (MVC) pattern.

Django

Django

Django is a high-level Python Web framework that encourages rapid development and clean, pragmatic design.

Laravel

Laravel

It is a web application framework with expressive, elegant syntax. It attempts to take the pain out of development by easing common tasks used in the majority of web projects, such as authentication, routing, sessions, and caching.

.NET

.NET

.NET is a general purpose development platform. With .NET, you can use multiple languages, editors, and libraries to build native applications for web, mobile, desktop, gaming, and IoT for Windows, macOS, Linux, Android, and more.

ASP.NET Core

ASP.NET Core

A free and open-source web framework, and higher performance than ASP.NET, developed by Microsoft and the community. It is a modular framework that runs on both the full .NET Framework, on Windows, and the cross-platform .NET Core.

Symfony

Symfony

It is written with speed and flexibility in mind. It allows developers to build better and easy to maintain websites with PHP..

Spring

Spring

A key element of Spring is infrastructural support at the application level: Spring focuses on the "plumbing" of enterprise applications so that teams can focus on application-level business logic, without unnecessary ties to specific deployment environments.

Spring Boot

Spring Boot

Spring Boot makes it easy to create stand-alone, production-grade Spring based Applications that you can "just run". We take an opinionated view of the Spring platform and third-party libraries so you can get started with minimum fuss. Most Spring Boot applications need very little Spring configuration.

Android SDK

Android SDK

Android provides a rich application framework that allows you to build innovative apps and games for mobile devices in a Java language environment.

Related Comparisons

Bootstrap
Materialize

Bootstrap vs Materialize

Laravel
Django

Django vs Laravel vs Node.js

Bootstrap
Foundation

Bootstrap vs Foundation vs Material UI

Node.js
Spring Boot

Node.js vs Spring-Boot

Liquibase
Flyway

Flyway vs Liquibase