🚀 The Simple Version
REST is a restaurant with a fixed menu — you order "the combo #4" and get exactly what's on it, nothing more, nothing less. GraphQL is a buffet where you point at exactly what you want, and get exactly that, no more.
REST in Practice
Each URL returns a fixed shape of data. GET /users/12 might return the user's name, email, bio, AND their last 50 posts — even if your screen only needs the name. You either get the whole plate or nothing.
GraphQL in Practice
You send one query describing exactly the fields you want:
{
user(id: 12) {
name
}
}
You get back exactly { name: "..." } — nothing extra. This is genuinely useful when your app has many different screens each needing slightly different data from the same underlying source.
Which Should You Learn First?
REST. It's simpler, it's everywhere, and almost every API you'll integrate with as a student (weather, payments, maps) is REST. Learn GraphQL once you've built two or three REST projects and start feeling the "why am I fetching all this extra data I don't need" pain yourself.
The Honest Trade-off
GraphQL gives the frontend more control but makes the backend more complex to build correctly (especially around performance and security). REST is simpler to build and reason about but sometimes over- or under-fetches data. Neither is "better" — they solve different pains.