Simply go to Google’s utility for search:http://www.google.com/cse/manage/create
and create a search account – it’s an easy 2.5 step process.
The third part of it is called “3. Get the code” where you will see a code to use (if you’re a programmer). Copy from this code the combination of digits and letters which appear between hyphens after this line:
var customSearchControl = new google.search.CustomSearchControl
And paste it into the widget on your WP admin. There are “settings” for this widget in the admin’s “settings” tab.