2 - Copy the URL
Press Command + L to go to the address bar and then Command + C to copy the URL to your clipboard. This will need to go into Alfred.
3 - Invoke Alfred -> Features -> Web Search
From here, click on Add Custom Search in the bottom right hand corner
4 - Paste the URL
In the first field, named Search URL, paste in the URL you just copied with Command + V. Be sure to replace the search term with the query in curly brackets, as below. Instructions are there underneath the field. You could, alternatively, just type in the name of the domain and press the Lookup button and if the site supports OpenSearch or SearchAction, Alfred can find the correct URL automatically.
5 - Assign a Title and Keyword
Give the Custom Action a title - this is what is going to be shown in the search results. Then assign the keyword, or the abbreviation, that will be used to instigate the search.
6 - Test
Some text is already filled in the validation field - Alfredapp - and if you click the Test button to the right, then Alfred will carry out a test search on that site.
If it works, click Save.