Doing your tax online is easy (well, at least not much more difficult than doing it in person). Also, you’ll save the costs of the forms which the Hacienda charge you for.
To be able to do your tax online, you’ll first need to get your electronic signature (“firma electrónica” or “certificado digital”).
Getting the certificado digital
Follow this link, which takes you to the Real Casa de la Moneda (Royal Mint). Type in your NIE (resident’s number), and you’ll be given a code. Take this code, along with your NIE and your passport, to your local Agencia Tributaria. When you get back home, download your electronic signature.
Note: Electronic signatures are attached to specific computers/tablets and specific browsers. So you won’t be able to do your tax from another computer. You can export security certificates from one device/browser to another. Try looking up “export security certificate” in Google for info on how to do this in your browser.