Creating Custom Searches with Alfred


I use Alfred for a lot of different things. It’s an app launcher, a currency converter, dictionary, calculator - in short, I try to use it as my shortcut for anything and everything that I do on my Mac. 

One great feature is the ability to search for content on different websites directly from the Alfred input bar. All I have to do is type in google or imdb followed by the search criteria and Alfred is able to invoke those searches, all from a compact and hassle-free interface. 

There are lots of default sites and services searchable by default, easily accessible by opening Alfred Preferences -> Features -> Web Search (see the below screenshot for the list). As you can see, the most common sites are certainly taken care of. There are occasions, however, when I want to search for content within a different site. My own is a great example! Am I able to configure an Alfred search workflow to trawl for content on a custom site? 

You bet you can! 

Here’s how:

1 - Identify the Search URL

Before I can configure a custom search, I need to know how my site handles search queries. The easiest way to do this is to navigate to my site and carry out a search. I have a search text entry field on my home page, so entering omnifocus as my search criteria took me to the following URL:

Dropping the Omnifocus from the end gives me the custom search URL in use on my site. I need to take that and enter this in Alfred. 

2 - Add Custom Search

Go to Alfred Preferences -> Features -> Web Search and in the bottom right-hand corner, click the option to Add Custom Search

In the resulting pop-up box, enter the Custom Search URL retrieved earlier into the first field. Fill in the remaining fields, paying careful attention to the Keyword field. This is the abbreviation you will type in to invoke the search. This needs to be unique and memorable. MPM is easy for me, so I go with this. 

You can validate the search by clicking the Test button. If successful, it will navigate to the custom site.

It’s that simple! If you find yourself performing lots of searches in sites that are not listed in Alfred by default - such as forums, discussion sites, game reviews etc, this is a great shortcut.