Home/Blog/Good to know

Digital certificate: how to install and use it

A digital certificate (certificado digital, also called an e-signature) is an electronic certificate in your name. With it you can log in to the websites of the Spanish tax agency (Hacienda), Social Security (Seguridad Social) and your town hall (ayuntamiento): view your data, receive notifications, download certificates and submit applications online without visiting an office. This article is for those who already have a certificate: how to install it and how to use it.

Installing it on a computer

Windows

  1. Double-click the .pfx (or .p12) file.
  2. The import wizard opens: click “Next” and enter the file's password.
  3. Let the certificate store be selected automatically and finish the installation.

Your browsers will then be able to see the certificate.

Mac

  1. Double-click the .pfx file and the Keychain Access app opens.
  2. Choose the “login” keychain and enter the file's password.

Your browsers will then be able to see the certificate.

Installing it on a phone

  • Android: send the file to your phone and open it, or go to Settings → Security → Encryption & credentials → Install a certificate. Enter the password.
  • iPhone: unlike Android, you first need to save the file on the phone itself, for example in the Files app. Only then tap it, and “Profile Downloaded” will appear in Settings. Install it and enter the password.

The names of the menu items may vary slightly depending on your phone model.

How to log in to Hacienda and Social Security

  1. Open the relevant website (sede electrónica, the online office).
  2. Choose the “Certificado electrónico” or “DNIe / certificado electrónico” login option.
  3. Your browser will show a window with a list of certificates: select yours and confirm.

Useful things you can do with it

  • View your data: tax returns and payments with Hacienda, your contribution record and contributions with Social Security.
  • Download certificates: for example, a certificate of no debts or your employment history (vida laboral).
  • Read notifications. Official letters from Hacienda and other authorities arrive in an electronic mailbox (Dirección Electrónica Habilitada única, DEHú). If you are required to receive notifications electronically, they are deemed delivered even if you have not opened them. So check it regularly, or arrange for us to do it for you.

Common mistakes

  • No copy of the file. If your computer breaks or is replaced, the certificate goes with it. Keep a separate copy of the .pfx file, for example in the cloud.
  • Forgotten file password. It cannot be recovered, so you will need a new copy or a new certificate.
  • Expired certificate. Renewing is easier while it is still valid; a reminder is usually sent in advance.
  • The browser has “remembered” an error and won't let you in. Sometimes, after a failed attempt, the browser remembers the wrong choice and shows an error straight away the next time you log in. Open the same website in incognito mode (a private window), and the browser will ask you to choose the certificate again.

Don't have a certificate yet, or having trouble installing it? Write to us. We can help, including remotely.

This is not legal advice. Updated September 2026.

Still have questions?Message us and we will look at your case.
Message us on WhatsApp
← All blog posts