Two grounds
Under article 1112 of the Civil Code, an inheritance passes by will or by law. If there is no will, or the will does not decide the fate of the whole inheritance, succession by law applies. Heirs by law are called in order of priority (article 1134).
The six-month period
Under article 1146 of the Civil Code, the notary at the place where the inheritance opened must issue the certificate of the right to inherit at the heir's request. The certificate is issued six months after the day the inheritance opened. If the notary has information that there are no heirs other than those who applied, the certificate may be issued earlier.
What to do
Under article 1145 of the Civil Code, the heir acquires the inheritance due to them from the moment the inheritance opens, unless the heir later renounces it or is deprived of the right to inherit. Apply for the certificate to the notary at the place where the inheritance opened. Under article 1117, that place is the last permanent residence of the deceased. Under article 1147, renunciation of the inheritance is also filed with that notary, and it cannot be cancelled afterwards.
Prepare the documents
Prepare these before you visit the notary: the death certificate, documents that confirm the family relationship, information on the last residence of the deceased, and the property documents.