You can obtain a digital certificate by applying to a certificate authority (CA), which is responsible for generating codes or keys on your behalf. You can then receive your pair of public and private keys and a certificate containing the public key along with a valid CA signature. Note, however, that there may be instances when an applicant may need to personally meet with a CA representative to validate his/her identity.
It is your responsibility to keep your private key secure at all times. Compromised or lost private keys must always be communicated with the issuing CA.
If you don’t want to purchase a digital certificate, you can still digitally sign your documents by creating a self-signed certificate. However, other people who will receive your digitally signed document can’t check its authenticity.