How searxng/searxng works
SearXNG is a privacy-focused metasearch engine: users submit searches, the server parses queries and dispatches work to configured search engines, then combines results for presentation. The graph also preserves documented engine integrations, browser-side search features, and supporting state and metrics. Relationships are limited to those named in the README or SOURCE INDEX; several runtime details and frontend connections are not shown in the sampled excerpts, so they are omitted rather than inferred.
Main entry points: search/__init__.py Search runtime · router.ts UI router · webapp.py Web request handling · engines/__init__.py Engine registry
Components 28
Web interface
- Web request handling
searx/webapp.py - Browser search UI
client/simple/src/js/main/search.ts - UI router
client/simple/src/js/router.ts - Keyboard controls
client/simple/src/js/main/keyboard.ts - Autocomplete
client/simple/src/js/main/autocomplete.ts - Preferences UI
client/simple/src/js/main/preferences.ts - Results UI
client/simple/src/js/main/results.ts - Browser plugins
client/simple/src/js/plugin/InfiniteScroll.ts
Search orchestration
- Query parsing
searx/query.py - Search runtime
searx/search/__init__.py - Engine processors
searx/search/processors/abstract.py - Online processor
searx/search/processors/online.py - Result aggregation
searx/results.py - Typed results
searx/result_types/_base.py - Answer generation
searx/answerers/_core.py
Engine integrations
- Engine registry
searx/engines/__init__.py - Engine framework
searx/enginelib/__init__.py - Engine traits
searx/enginelib/traits.py - Search engine adapters
searx/engines
Shared services
- Network clients
searx/network/__init__.py - Settings loading
searx/settings_loader.py - User preferences
searx/preferences.py - Cache service
searx/cache.py - SQLite storage
searx/sqlitedb.py - Search metrics
searx/metrics/__init__.py - Server plugins
searx/plugins/_core.py
Other components
- Search user
- External search providers
Connections 26
- Search user → Web request handling: submits search
- UI router → Browser search UI: loads search
client/simple/src/js/router.ts - UI router → Keyboard controls: loads controls
client/simple/src/js/router.ts - UI router → Autocomplete: loads suggestions
client/simple/src/js/router.ts - UI router → Preferences UI: loads preferences
client/simple/src/js/router.ts - UI router → Results UI: loads results
client/simple/src/js/router.ts - UI router → Browser plugins: loads plugin
client/simple/src/js/router.ts - Web request handling → Query parsing: parses query
searx/webapp.py - Web request handling → Search runtime: starts search
searx/webapp.py - Web request handling → Settings loading: loads settings
searx/webapp.py - Search runtime → Engine registry: loads engines
searx/search/__init__.py - Search runtime → Network clients: initializes network
searx/search/__init__.py - Search runtime → Search metrics: initializes metrics
searx/search/__init__.py - Search runtime → Engine processors: dispatches engines
searx/search/__init__.py - Search runtime → Result aggregation: collects results
searx/search/__init__.py - Search runtime → Server plugins: runs plugins
searx/search/__init__.py - Engine processors → Online processor: registers processor
searx/search/processors/__init__.py - Engine processors → Engine registry: selects engine
searx/search/processors/__init__.py - Engine registry → Engine framework: configures engines
searx/engines/__init__.py - Engine registry → Engine traits: uses traits
searx/engines/__init__.py - Search engine adapters → External search providers: queries providers
- Online processor → Network clients: sends requests
- Result aggregation → Typed results: holds results
- Answer generation → Typed results: creates answers
searx/answerers/_core.py - Cache service → SQLite storage: uses storage
searx/cache.py - Web request handling → User preferences: reads preferences
searx/webapp.py