I had some difficulty trying to figure out how to do this, then made the discovery by accident.
Once YaCy is running, well first add a separate search bar in Firefox preferences, then when you open the YaCy search page, the option to add YaCy will appear when typing into the search field.
I thought this might be helpful to anyone trying to implement a convenient way to use YaCy in Firefox. It took me several weeks before I discovered this so perhaps it will save someone else some unnecessary time and frustration.
To make it even better, you can also set the shortcut to a easy to use keyword like
@yacy and search from the address bar
It looks like mozilla hid the option to add custom search engines but the option is still present.
See Set up custom default search URL | Firefox Support Forum | Mozilla Support
about:config, set browser.urlbar.update2.engineAliasRefresh to
about:preferences, now you can “Add” to search engines.
http://localhost:8090/yacysearch.html?query=%252Flanguage%252Fen+%s as the Engine URL term.