LLearnViaNotes @learnvianotes· 1 min read REST for web/mobile, GraphQL for complex UIs, gRPC for microservices, WebSockets for real-time. Architecture choice shapes everything downstream.
| Criterion | REST | GraphQL | gRPC | WebSocket |
|---|
| Protocol | HTTP/1.1 | HTTP/1.1 | HTTP/2 | WS over TCP |
| Payload | JSON/XML | JSON | Binary (protobuf) | Any |
| Typing | Untyped | Schema-typed | Strongly typed | Untyped |
| Streaming | No | Subscriptions | Native 4 modes | Native |
| Caching | HTTP cache | App-level | No HTTP cache | No |
| Browser support | ✓ Native | ✓ Native | Needs proxy | ✓ Native |
| Best use | Public APIs | Complex UIs | Internal svcs | Real-time |
Free for students and teachers
Write notes like this one
Cards for every idea, quizzes and flashcards, read aloud — on the web and your phone.
Something wrong with this note? Open it to report