skillfed

graphql-server

A library setting up a GraphQL server in a variety of frameworks

graphql-server v3.0.0 151.9K downloads/30d#10,918 on PyPI134
Permissive license MIT AGING released

What it is and what it does

GraphQL-Server is a base library that wraps graphql-core to provide a standardized interface for executing GraphQL queries, mutations, and subscriptions across multiple Python web frameworks. It passes all GraphQL specification tests and supports synchronous execution, asynchronous views, file uploads, and WebSocket-based subscriptions. Rather than being a standalone server, it acts as a bridge—you use its core functions (execute, execute_sync, subscribe) within your chosen framework (Django, Flask, FastAPI, aiohttp, Sanic, Channels, Litestar, Quart, Chalice, WebOb, or ASGI) to handle GraphQL operations.

The package is intended for developers building GraphQL APIs on top of existing Python web infrastructure. It handles the protocol and execution details so you can focus on schema design and resolver logic. The library includes type hints and docstrings throughout, and the repository provides integration examples for each supported framework.

Use it for:

  • Add GraphQL query execution to a FastAPI or Flask application without building the execution layer from scratch.
  • Implement WebSocket-based GraphQL subscriptions in a Django or aiohttp application using the subscribe function.
  • Handle file uploads in GraphQL mutations across multiple framework backends using the built-in Upload support.
  • Migrate a GraphQL server from one framework to another by reusing the same graphql_server integration pattern.
  • Build a custom GraphQL server on top of a framework not yet listed by using the public execute/execute_sync/subscribe functions as a blueprint.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

GraphQL-Server provides helper functions to execute GraphQL queries and subscriptions on top of graphql-core, designed to integrate with Python web frameworks like Django, Flask, FastAPI, and others.

Yes, if you are building a GraphQL API in Python and want a framework-agnostic execution layer. The low install friction, MIT license, and broad framework support make it a practical choice. The 362-day release gap warrants checking whether the project's maintenance pace matches your needs, but the stable classifier and zero known vulnerabilities suggest it is suitable for production use.

Install

graphql-server on PyPI

pip

pip install graphql-server

uv

uv add graphql-server

poetry

poetry add graphql-server

Installing graphql-server

Before you install

Low install friction; depends only on graphql-core. Maintenance status is aging—last release was 362 days ago, though the repository remains active and the package is marked Production/Stable.

License in practice

MIT license permits commercial and private use with minimal restrictions; you may use, modify, and distribute this package freely provided you include the license notice.

Quickstart

pip install graphql-server

from graphql_server import execute_sync
from graphql import build_schema

schema = build_schema('type Query { hello: String }')
result = execute_sync(schema, '{ hello }')

Requires Python 3.9 or later; graphql-core must be installed as a runtime dependency.

Verify before relying

  • Whether the 362-day gap since last release indicates active maintenance or dormancy relative to the project's typical release cadence.
  • Performance characteristics and scalability limits for concurrent subscriptions or high-volume query execution.

Package facts

License MIT (permissive)
Python support supports the current Python release (<4.0,>=3.9)
Install friction low — pure-Python wheel
Runtime dependencies 1 — graphql-core
Maintenance aging — 362 days since the last release
Last repo commit
First released
Downloads 151,881/month — #10,918 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: graphql_server-3.0.0-py3-none-any.whl

Keywords: graphql, api, rest, starlette, async, fastapi, django, flask, litestar, sanic, channels, aiohttp, chalice, webob, pyright, mypy, codeflash

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseTopic :: Software Development :: LibrariesTopic :: Software Development :: Libraries :: Python Modules

Tags

graphql server pythongraphql framework integrationgraphql async subscriptionsgraphql web framework adaptergraphql query executiongraphql websocket supportgraphql file uploads
graphqlweb-framework-adapterasync-support

More Libraries packages