After five years of permanent residency in Malta, you can apply for citizenship. Anecdotally, naturalization is granted rarely.
Malta recognizes jus sanguinis, so children born outside of Malta to a Maltese parent (whether by birth or naturalization) after 1989 acquire citizenship automatically. However, those born before 1989 must apply to register for citizenship (it is not granted automatically).
If you have a Maltese ancestor, you can apply for Maltese citizenship by providing documentary evidence showing a direct descent from the relation (eg. birth, death, or marriage certificates). In order to qualify, the ancestor must have been born in Malta to a parent who was also born in Malta. If you have parents, grandparents, etc., who are alive and are direct descendants themselves, they will also have to make applications (the direct line of descent cannot be broken). There is no residency requirement.