LLMpediaThe first transparent, open encyclopedia generated by LLMs

gRPC-Web

Generated by GPT-5-mini
Note: This article was automatically generated by a large language model (LLM) from purely parametric knowledge (no retrieval). It may contain inaccuracies or hallucinations. This encyclopedia is part of a research project currently under review.
Article Genealogy
Parent: GraphQL Hop 5
Expansion Funnel Raw 90 → Dedup 0 → NER 0 → Enqueued 0
1. Extracted90
2. After dedup0 (None)
3. After NER0 ()
4. Enqueued0 ()
gRPC-Web
NamegRPC-Web
DeveloperGoogle
Released2018
Programming languageC++, Java, JavaScript, TypeScript
Operating systemCross-platform
LicenseApache License 2.0

gRPC-Web is a protocol and set of libraries that enable web browsers to call remote procedure call (RPC) services built with gRPC server implementations. It provides a bridge between modern web clients and backend services created by organizations like Google and projects associated with the Cloud Native Computing Foundation, enabling developers familiar with frameworks from Facebook to interoperate with ecosystems influenced by Netflix and Twitter. The project integrates with common web stacks used by teams at companies such as Microsoft, Amazon, IBM, Red Hat, and GitHub.

Overview

gRPC-Web adapts the gRPC model to the constraints of browsers that implement standards from bodies like the World Wide Web Consortium, enabling unary and streaming RPCs over HTTP/1.1 or HTTP/2 transports used by Chromium, Mozilla Foundation (Firefox), Apple (Safari), and Microsoft Edge. The initiative complements ecosystem tools from Kubernetes, Istio, Envoy, and Linkerd by allowing front-end code written with frameworks such as React (web framework), Angular (web framework), Vue.js, Svelte (software), or Ember.js to communicate with microservices designed with languages like Java (programming language), Go (programming language), C++, Python (programming language), and Node.js. The design balances compatibility with browser security models implemented by projects such as Content Security Policy and deployment patterns used by companies like Salesforce and Adobe.

Architecture and Protocol

gRPC-Web defines a wire protocol that maps Protocol Buffers serialized messages into HTTP requests and responses compatible with browser APIs such as the Fetch API and XMLHttpRequest. It relies on intermediary proxies like Envoy (software) or platform-specific gateways to translate between gRPC over HTTP/2 and browser-oriented transports, mirroring approaches used by NGINX, HAProxy, and Traefik. The protocol supports unary calls and server streaming, integrating with server-side frameworks from Spring Framework, Express (web framework), Django, and ASP.NET Core. Interoperability considerations reference specifications from RFC 7230 and RFC 7540 and patterns implemented in projects by Google Cloud Platform, Amazon Web Services, and Microsoft Azure.

Implementations and Tooling

Official and community implementations exist in languages and toolchains maintained by organizations including Google, Square, Inc., Lightbend, and open-source contributors from foundations such as the Linux Foundation. Tooling includes code generators that extend the protoc toolchain used across projects like TensorFlow and Istio to produce client stubs for TypeScript (programming language), JavaScript, and language-specific server plugins for Go (programming language), Java (programming language), C#, and Python (programming language). Integrations with build systems such as Bazel, Maven, Gradle, npm, and yarn assist teams using continuous integration platforms like Jenkins, GitLab CI, CircleCI, and GitHub Actions.

Usage and Integration

Developers incorporate gRPC-Web into applications that follow deployment patterns practiced by companies such as Uber Technologies, Airbnb, Spotify, and Dropbox to connect single-page applications (SPAs) with backend microservices. Typical architectures use proxies like Envoy (software) or service meshes like Istio to mediate traffic, and observability tools from Prometheus, Grafana, Jaeger (software), and OpenTelemetry for tracing and metrics. Client applications built with React (web framework), Angular (web framework), or Vue.js call services implemented with frameworks from Spring Boot, Express (web framework), or ASP.NET Core, while authentication is frequently handled via identity providers such as OAuth 2.0 implementations from Okta, Auth0, Azure Active Directory, or Google Identity Platform.

Security and Performance Considerations

Security best practices mirror patterns established by OWASP and network operators at Cloudflare and Akamai Technologies: use TLS termination, enforce policies from Content Security Policy, and integrate token-based authentication from providers like Keycloak and Auth0. Proxies such as Envoy (software) support rate limiting, TLS offload, and mutual TLS (mTLS) models used in enterprises like Salesforce and IBM. Performance tuning draws on techniques used by teams at Facebook and Netflix: enable HTTP/2 where possible, configure connection pooling in NGINX or HAProxy, and apply compression strategies similar to those used in gRPC core implementations. Monitoring relies on telemetry standards pushed by OpenTelemetry and aggregation systems such as Prometheus and Grafana.

History and Development

Origins trace to engineering efforts within Google to broaden gRPC reach into web platforms constrained by browser APIs defined by the World Wide Web Consortium. Community engagement and contributions have been coordinated through repositories and organizations such as GitHub, with adopters and contributors from Netflix, Square, Inc., Lightbend, Red Hat, and independent maintainers. The project evolved alongside developments in Envoy (software), the Cloud Native Computing Foundation, and service mesh research from Buoyant and Linkerd.

Comparison with Alternatives

Compared with full-duplex WebSocket-based RPC approaches employed by companies like Twitch and Discord, gRPC-Web favors compatibility with existing HTTP infrastructure used by Google Cloud Platform and Amazon Web Services. Alternatives such as RESTful JSON APIs common at Twitter and Facebook offer broader tooling but less compact binary serialization than Protocol Buffers, used in gRPC-Web implementations. Other RPC-over-HTTP solutions, including JSON-RPC implementations used in projects like Ethereum clients, and GraphQL deployments by teams at GitHub and Shopify, emphasize different trade-offs in schema flexibility, tooling, and caching.

Category:Remote procedure call protocols