Using keyword searches
From MozillaZine Knowledge Base
In Firefox and Mozilla Suite you can specify keywords for bookmarks by filling in the “Keyword” field in the bookmark’s Properties. When you type the keyword into the Location Bar and hit [Enter], the keyword will be replaced with the bookmarked URL. For example, bookmarking http://google.com/, giving it a keyword of “g”, and typing “g” into the Location Bar will take you to Google.
What makes keywords very powerful is that if you add a “%s” at some place in your bookmark’s URL, it will be replaced by the words you type in after the keyword. (These are sometimes called “Quicksearches”.) For example, if we were to modify the bookmark mentioned above so that it pointed to “http://google.com/?q=%s”, we can type “g mozilla” into the Location Bar to arrive at “http://google.com/search?q=mozilla”.
By default, Mozilla Firefox comes with several bookmarks with keywords defined. They’re located in the “Quick Searches” folder in the default bookmarks.
Firefox no longer supplies a set of default keyword shortcuts, though many people may have started with the above. You can easily add your own keyword shortcuts, such as one to search the MozillaZine Knowledge Base. You need not limit yourself to letters alone, which might be mistaken for search words. Also a keyword of "g:" would be a lot faster to type than the suggestion above of "google".
Creating bookmarks with keywords
In Mozilla Firefox, you can simply right-click in a search field on a web page and choose “Add a Keyword for this Search.” This will pop up a dialog for you to add a bookmark name and keyword.
You can also create it manually:
Difference between (small s) %s and (Capital S) %S
Note: Mozilla Suite users can use the “Bookmarks → File Bookmark...” feature and edit bookmark’s properties at the moment of its creation.
Note: Firefox users with Add Bookmark Here ² extension, or the older Open Book extension, can create a bookmark and add keyword property at the same time. An alternative is Keyword addition for Add/Change Bookmark (Fx3) | userstyles.org as a style used with the Stylish extension that can be customized.
Specifying a non-UTF-8 encoding in the query
By default, %s-replaced query terms are sent to the server in UTF-8 encoding. Some servers, however, use other encoding in their query string, especially in the non-Western environment to result in misinterpreted or garbled query. The mozcharset= parameter has been introduced to work around this problem in Bug 258223.
For example, Korean computer jargon dictionary uses EUC-KR encoding. Normal keyword search such as,
produces incorrect result when supplied with non-ASCII query term 파일. By appending mozcharset=charset parameter, as in
users are directed to the correct result page.
Caveat: mozcharset=charset parameter should be appended at the end of the query string with the preceding &.