Deploy searchapi

SearchAPI is a api only search engine built on top of searxng

Deploy searchapi

pratyay360/searchapi:latest

pratyay360/searchapi:latest

Just deployed

Deploy and Host searchapi on Railway

searchapi is a free, SearXNG-style meta search API built with FastAPI. It provides REST endpoints for web, PDF, wiki, news, books, repositories, and academic-paper search. It also works as an MCP server, allowing LLM clients and AI agents to consume the same search capabilities without paid API keys or query quotas.

About Hosting searchapi

searchapi is a stateless FastAPI service served by Uvicorn and packaged in a container, making it straightforward to deploy on Railway. You can deploy directly from the repository or use the prebuilt GHCR image, expose the application port, and connect it to the public internet. The service requires outbound internet access to communicate with upstream search engines but does not require a database, cache server, or message broker. A single Railway instance is sufficient for modest traffic, while larger workloads can scale vertically or horizontally with multiple replicas.

Common Use Cases

  • LLM data collection and RAG pipelines — provide structured web, PDF, and academic search results to retrieval and agentic workflows.
  • Backend search for applications and bots — integrate endpoints such as /search, /news, /wiki, /books, and /repositories without relying on paid search APIs.
  • Research and discovery tools — search academic papers, PDFs, repositories, news, books, and other sources from a single API.

Dependencies for searchapi Hosting

  • Python 3.13+ and uv — used for dependency management and running the FastAPI application. The included Containerfile handles the environment setup.
  • Outbound internet access — required to query upstream search engines through the application's HTTP clients. No database or other persistent infrastructure is required.

Implementation Details

The repository includes a container configuration suitable for Railway:

FROM ghcr.io/astral-sh/uv:alpine

WORKDIR /app

ENV UV_NO_DEV=1
ENV PYTHONUNBUFFERED=1

COPY . .

RUN uv sync --frozen

EXPOSE 8000

CMD ["uv", "run", "fastapi", "run"]

Configure Railway to listen on the PORT environment variable and bind the server to 0.0.0.0 (for example, by passing --host 0.0.0.0 --port $PORT to the start command). The application exposes:

  • Health check: /health — returns {"status": "ok"}
  • MCP endpoint: /mcp — connect MCP-compatible clients using your Railway deployment URL.
  • Search endpoints: web, news, wiki, books, repositories, PDF, and academic search.

Search concurrency, result limits, and cache behavior can be tuned through the search service configuration. For heavier workloads, consider using an outbound proxy and appropriate request delays to reduce upstream rate limiting and CAPTCHA challenges.

Why Deploy searchapi on Railway?

Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.

By deploying searchapi on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.


Template Content

pratyay360/searchapi:latest

quay.io/pratyay360/searchapi:latest

More templates in this category

View Template
Chat Chat
Chat Chat, your own unified chat and search to AI platform.

okisdev
117
View Template
stella
Self-host stella with web, API, Postgres, Redis, and object storage.

Jan Kubica
7
View Template
Hermes Agent | OpenClaw Alternative with Dashboard
Self-Hosted Hermes AI Agent for Telegram, Discord & Slack

codestorm
86