The steps to create a gadget are really simple.
Create a folder with a suffix of “.gadget”
Put an HTML file in the folder
Put an XML file in the folder
Add your new gadget to the Sidebar.
You can see a complete walk-through of creating a Windows Sidebar Gadget online.