Extension Icon

Search Router

Local-first search with Kagi's !Bangs (similar to unduck.link with DuckDuckGo's !Bangs)
Overview

Search Router

Implements Kagi Search bangs directly in Raycast without sending traffic through a third party website πŸ”

What is Search Router?

Search Router lets you search specific websites from Raycast using shortcuts by implementing Kagi Search bangs. For example:

  • !g cats searches Google for "cats"
  • !w cats searches Wikipedia for "cats"
  • Help me fix my code !t3 uses t3.chat to ask AI to fix your code
  • markdown parser @gh searches for "markdown parser" specifically within Github's domain (site:github.com)
  • And many more! See all available bangs in Kagi Bang Explorer

Pro Tip: ✨ For the best experience, set up Search Router as a Fallback Command in Raycast. This allows you to use bangs directly from the main Raycast search without having to first open the extension!

Commands

Search the Web 🌐

Type your query with an optional bang prefix/suffix:

  • With search engine: !yt funny videos searches YouTube
  • Without search engine: funny videos uses your default search engine
  • Site-specific search: funny videos @yt searches for "funny videos" only within YouTube's domain

Browse Search Engines 🧭

View and manage all available search engines with filtering options. You can:

  • Filter by type: View all engines, only custom engines, or only built-in engines
  • Search: Find engines by name or trigger
  • Set default: Choose your default search engine
  • Manage custom engines: Add, edit, or delete your custom search engines directly
  • Copy details: Copy shortcuts or domains to clipboard

Add Custom Search Engine βž•

Quickly add a new custom search engine with a personalized trigger and URL.

Example custom search engines:

  • !jira for your company's Jira issue tracker: https://company.atlassian.net/browse/{{{s}}}
  • !cgitlab for a self hosted GitLab: https://gitlab.company.com/search?search={{{s}}}

Setting Up as a Fallback Command ⚑

For the most seamless experience:

  1. In Raycast, search for "Manage Fallback Commands"
  2. Add "Search the Web" from the Search Router extension to your enabled fallback commands
  3. Now you can use bangs directly from Raycast's main search when no other results match!

Contributing

Contributions welcome! Submit a pull request to add more search engines or improvements.

Managing Search Engines

This extension uses search engine definitions from Kagi's bangs repository. Here's how to add or update search engines:

  1. To add a new built-in search engine:

    • Fork Kagi's bangs repository
    • Add your search engine definition following their schema
    • Submit a PR to Kagi's repository
  2. To update this extension with latest engines:

    • Fork this repository
    • Run npm run download-kagi-bangs to fetch latest definitions
    • Test locally with npm run dev
    • Submit a PR

Credits πŸ™