Login to Your Joomla Site

Go to example.com/administrator and login to your site.
Go to the Template Manager

Click on "Extensions" and then "Template Manager"
Open Your Default Template

rhuk_milkyway is my default template so I'll click on that name.
Open the Template Files

Click "Edit HTML" in the top-right corner.
Enter Your Code

Scroll all the way to the bottom of the page and post your code right above the final lines: . Then click "Save" in the top-right corner and you'll have finished.